In some cases, it is desirable to replace the controls generated by Iron Speed Designer with different controls. For example, you might wish to replace the TextBox control generated for FieldValue tags with a “MyTextBox” control and do this uniformly throughout all of your applications. There are several ways of doing this.
With this option, change the Iron Speed BaseClass library control you wish to replace to inherit from the replacement third-pary control. Your third-party control should in turn inherit from the .NET Framework’s control upon which the BaseClass library control originally inherited. Said another way, you are inserting your third-party control between the BaseClass library control and the .NET Framework control.
Using this method, all of the Iron Speed Designer controls will have the .NET, third-party, and BaseClass library functionality combined.
The new FieldValue type could be used directly in a layout page, for example by including:
<BaseClasses:MyNewFVClass... />
in the layout page. Your new type would automatically load and save data at all of the correct times. It could also be affected by code customization. However, Iron Speed Designer itself would be unaware of this new FieldValue type, so it would operate independently of the GEN:FieldValue tags, tag property setting in Iron Speed Designer, etc.
Creating a new FieldValue type could be done from scratch, though you might find it easier to:
Copy the Iron Speed BaseClass library’s FieldValueTextBox control class, wor whichever existing type is "closest" in implementation for your desired purpose.
Rename the copied class.
Change the copied class to inherit from the third-party control.
Modify, if necessary, the implementation of the GetValue, SetValue, and other methods to attach those methods to the correct "data" in the base class, i.e. the 3rd-party control.
You can customize the page(s) code-behinds to manually load and save database data to and from the third-party control at the appropriate times. The custom code for this will vary in complexity depending on the type, contents, and nesting of the page's server controls.
Set the FieldValue tag to be invisible via the Page Properties dialog, and use single value data binding and/or code customization to make sure data/selection changes to the controls automatically propagate to the other control. The custom code for this will also vary in complexity, but is probably easier than including the third-party control in the layout pages directly.
Independent Third-Party Controls