Custom and User-Defined Custom Components
- Custom Components
- Creating a Custom Component
Creating a custom component involves four steps.
- Custom Component Sections and Events
Let's go over the Sections and Events of the Custom Component Builder.
How to make an Ajax callback and maintain state across HTTP calls.
- Sharing and Using a Custom Component
- User-defined Components
A User-defined Component is the more flexible big brother of a Custom Component. Like a Custom Component, a User-defined Component can be opened in a window, a DIV, or a Tabbed UI Pane, in a linked content section of a Grid, and in a row expander of a Grid. Like a Custom Component, a User-defined Component has bindable arguments.
- When to turn a Custom Component into a User-defined Component
In addition to the bindable arguments of a Custom Component, a User-defined Component has properties and supports having property grids for user input. Bindable properties make it possible to bind data to exposed properties programmatically, which in turn makes it possible to send the User-defined Component arrays of data or data generated from Xbasic expressions. Property grids, used widely in Alpha Anywhere and prominent as the control panel for grid creation, make setting up the User-defined Component a matter of a few mouse clicks.
- Creating a User-defined Component
Follow these steps to create a User-defined Component.
- Creating a Property Grid for a User-defined Component
One way to create a Property Grid for a User-defined Component is to use the Property Grid builder in Action Scripting to generate the markup. This is invoked by creating a New Script (using Action Scripting), adding a new action, and selecting Xdialog Windows|Display an Xdialog Box.
- Sharing and Using a User-defined Component
Once you have a working User-defined Component, you can share it with others by sending them a Zip of the entire directory tree you used to create the User-defined Component builder. They will need to unpack it into their C:\ProgramData\Alpha Software\Alpha Five Version 11\Installations\<identifier>\UserDefinedWebComponentTypes directory, which they can find by using the Edit|Advanced|Open Folder where User-defined Components are Registered menu item from Alpha Five.