versago:create_a_basic_form

Creating a Basic Standard Form

The following steps illustrate the process of creating a basic standard Versago (v2) form. It uses the application to create the underlying database table and includes examples of various types of controls.

Define New Form Information

The basic required information includes the values shown in the image below.

In this example we are assigning only one role. In most cases the form will be associated with multiple roles.

The database that will hold the associated table is VersagoData. Your database name may be different.

Define the Database Table

In this example we show the typical database columns used for a Versago form as well as columns that will be used for control examples.

Creating the Form Layout

Initial View

The initial view is a single row with four columns. Additional rows can be added before adding controls or the initial controls can be added before continuing. The control for the primary key field (vgoRecNum) must be added to the form before it can be saved.

Initial Controls

Four key controls are added into the initial row. These controls are all set as “read-only” since they are automatically populated based on the default values shown.

Add database field (header) vgoRecNum with caption of Record ID

Add database field (header) vgoCreatedBy with caption of Created By

Add database field (header) vgoCreateDate with caption of Date Created

Add database field (header) vgoCreatedById with caption of Created by ID

Note that this control is not visible since it is for internal use only but does need to be captured in the record.

The row after the controls have been added will appear like this:

And this is what the user will see:

Additional Rows & Controls

Add a 1 x 1 row and Section Title control

What the user sees:

Add a 1 x 3 row

Change column widths

The original widths were 4,4,4 so all columns are the same width. With the change columns 1 and 2 are smaller and 3 is larger.

Add text and numeric controls

In this example the two numeric fields use a default of 0. This is to illustrate what the user sees when a value is entered in the field. The default is not required and may not be useful in a production form.

Add database field (header) NumericInt with caption of Integer and default of 0.

Add database field (header) NumericDecimal with caption of Numeric Decimal, Decimal Place of 4, and default of 0.

Add database field (header) TextBox1 with caption of “Text (100 char max)”

What the user sees:

Add another 1 x 1 row and Section Title (Date Controls)

Add a 1 x 4 row

Add Date and Time controls (3)

Add database field (header) DateAndTime with caption of “Date and Time”, a format of DateTime, and the Culture as shown.

Add database field (header) DateOnly with caption of “Date Only”, a format of Date, and the Culture as shown.

Add database field (header) TimeOnly with caption of “Time Only.” The Control Type is changed to Time Picker. The format is DateTime and the Culture is as shown.

Column 2 is left empty for spacing (as an example).

What the user sees:

Image to follow

Add another 1 x 1 row and Section Title (DDL and Lookup)

Add a 1 x 4 row

Add database field (header) StaticDDL with caption “StaticDDL”.

This will be static drop-down with the values Yes, No, and Maybe.

Change the Control Type to “Drop-down List” from the drop-down selections.

Set the “Lookup List” to ‘Static from the drop-down selections.

Enter the values in the “Static List” text box. Separate values with a comma.

What the user sees:

Add Lookup Controls

In this example we will use one control to look up customers by name and a second control to hold the corresponding customer code.

Add database fields (header) Lookup1 in column 2 and Lookup2 in column 3.

  • Set the caption of Lookup1 as “Customer Name” and the caption of Lookup2 as “Customer Code.”
  • Clear the “Editable” checkbox on Lookup2 as this value will be filled in by the lookup.

Return to the Lookup1 control to edit and set up the lookup.

Select the lookup report. In this case we will use “Customer Lookup by Name.” This report has already been defined. Your report will most likely have a different name.

Click on the editing button […] to set up the lookup.

Match the input field of the report to the control on the form.

Match the output fields on the form to the appropriate values in the report.

What the user sees (before lookup):

What the user sees (after lookup):

Add another 1 x 1 row and Section Title (Signature)

Add a 1 x 1 row

Add database field (header) SignatureData with caption of “Signature”.

Change the Control Type to Signature from the drop-down selection list.

Change the Row Span value to a minimum of 2. This value reflects the vertical height of the signature box.

What the user sees:

The basic form is now complete.

versago/create_a_basic_form.txt · Last modified: 2019/08/01 10:48 by runger