Designer: See the Designer User's Guide for more information on creating a virtual data form.
Code: As you can see from the code example, the steps for defining and using a virtual form are the same as those for data forms that are not virtual, except for Step 4.
| 1 | Include the header files for each field type in the form. Include vv_main.h as the last Vermont Views header file in your main program. |
| 2 | Declare the data variables and a pointer to a form structure. A virtual form is the same data type as a normal form, DFORMPTR. |
| 3 | Initialize the data variables. |
| 4 | Define a virtual data form with fm_vdef(). |
| 5 | Define the items on the form. The coordinate system is based on the number of rows and columns of the underlying virtual form, not the form window. |
| 6 | Process the form with fm_proc(). |
| 7 | Collect the data from the variables. |
| 8 | Free the memory allocated for the form with fm_free(). |
| 9 | Free the memory allocated for the data variables. |