Mobile Dynamic Form

This WorkWithPlus for Native Mobile feature allows GeneXus users to build data display or data entry forms using dynamic fields, which can be loaded in various ways. With this feature, the user can choose which fields and in which order the fields are shown, even in runtime. This is accomplished by loading a custom SDT provided by WorkWithPlus for Native Mobile.


MDF Template

The simplest way to create a Mobile Dynamic Form is to use the template wizard. Just open the template wizard and select "Mobile Dynamic Form" in the "Other" category.


Data Source

Once the template is applied, you must indicate which fields are displayed.

WorkWithPlus for Native Mobile MDF loads the fields using the SDT "MDFDynamicField". You will have to load this SDT with the data you want to display in the form. Typically, this will be done in the start or refresh event.


For each field you will have to indicate:

  • Name and id: This will identify the field.
  • Description: Text displayed in the form label.
  • Type: Data type of the field. Must be a value from the domain SDPMDFFieldType (Character, Numeric, Decimal, Date, Boolean, Combo)
  • Value: Default value for the field. Use the value according to the data type.
  • Enabled: Define if the field can be edited or not
  • Required: Defines if the field is required

WorkWithPlus for Native Mobile provides a procedure that shows some examples of how you can load the SDT. Please open the procedure "MDFLoadSampleFields" and check the sample. 


But, you can also load fields from a table. e.g. if you have a table with Questions from a survey you can load it like this:


Visual Customization

By default, all fields in the Dynamic Form will have the same look and feel. You can customize the UI for each field by using the following options in the SDT:

  • MDFDynamicFieldClass: Name of the theme class that will be applied to the field.
  • MDFDynamicFieldDescriptionClass: Name of the theme class that will be applied to the field label.