Field Setup
After loading the database, the database objects (tables, views, custom views and reports) will be shown in the left pane (the database pane). Click on any table to go to the Field Setup Page for that table at any time.
Note: For simplicity, we use "table" in the following description to refer to any of database object in the project. A database object can be either a table, a view, a custom view or a report.
ASP.NET Maker support all commonly used data type. If ASP.NET Maker finds any unsupported fields in a table, an [Unsupported Fields] tab will appear. You can click on the tab to view the list of fields that are not supported.
The Field Setup pages consists of two section. The upper section is a grid showing available options of all fields. The lower section contain two panels, the [Edit tag] panel and the [View tag] panel for the selected field.

The grid consists of the following sections:
General

Properties
| Field Name |
Field Name (read only) |
| Data Type |
Data Type (read only) |
| Size |
Maximum field length (read only) |
| Caption |
Caption to be displayed |
| Primary Key |
Primary Key of the table
Important Note:
- You should never change this field unless
you are absolutely sure that this field is unique. Otherwise a particular record cannot be located and unexpected results may occur.
- Composite key is supported. Primary key is uneditable in the edit page.
|
| Page No. |
Page number of the field. By default all the fields are in page 1 and multi-page is disabled.
Multi-page Add/Edit/View is supported. If you set any page number to larger than 1, multi-page feature will be enabled automatically.
From v7.0+ you can mutli-select the fields by ctrl-click or shift-click the Field Name column and then right click to set the page number for the selected fields simultanesouly. Page labels are also supported, see Table Setup. |
| Auto-Update Value |
A dynamic value to update the field function automatically in Add/Edit pages.
The dropdown list for this setting is preloaded with a few functions for your selection. For ex maple, you may want to record the last modified date of a record, then you can select "ew_CurrentDate". Do not select a function that return values of unmatching data type, for example, you should not select a function that return a non-numeric string for a numeric field.
Notes:
- This setting will make the field hidden automatically and it overrides the default value in Add page and custom value for Hidden Edit tag in Edit page. (see section below)
- You can add your own functions, the function must accept no argument and return a value. You can add your function names (comma separated) in the following registry key:
HKEY_CURRENT_USER\Software\ASPNETMaker\<Version>\Settings\General
Value: AutoUpdateValues
e.g. You can enter "MyAutoValueFunction1,MyAutoValueFunction2". Of course, you also need to include your shared functions in the generated scripts or in the template so it is available for use. Alternatively, you can put your functions in the Global Code section under Server Events. (See Server Events and Client Scripts.)
|
Custom field display order by drag-and-drop
You can change the field order defined in the database by simple drag-and-drop. Simply ctrl-click or shift-click the Field Name column to select the field, then drag it to where you want. ASP.NET Maker will generate scripts and display records according to this order.
List Page

Properties
| List |
Show field in list page |
| Export |
Include the field when export |
| Aggregate |
Enable Field Aggregation. Aggregated values will be shown at Page
Footer. Not applicable in multi-column view. Aggregate options include:
- TOTAL (sum of all field values in current page)
- COUNT (count of records in current page)
- AVERAGE (average field value in current page) |
| Width |
Specify field column width
e.g. If you enter "200px" (without quotes), the output will be style="width: 200px" |
| Wrap |
Enable/Disable wrapping of field value |
| Quick Search |
Include this field when performing Quick(Basic) Search in the List page.
Note: Only text fields and numeric fields are supported in Quick Search. By default only text fields are enabled. |
| Ext. Search |
Use this field in Extended Quick Search
Extended Quick Search is enhancement of Quick Search. It is sort of a combination of Quick Search and Advanced Search. If a field is checked for Ext. Search, a form element for the field will be shown in the Quick(Basic) Search form and the user input criteria for this field will be included when performing Quick(Basic) Search.
Extended Quick Search will use the same search operators specified under the "Advanced Search Page" section (see below).
|
View Page

Properties
| View |
Show field in view page |
| View Tag |
HTML tag to display the field.
Used in List/View pages. |
You can either click the [View Tag] column and select a View Tag from the drop down box
or click the icon on the View Tag panel toolbar to select. After selecting the View Tag, you can further setup its properties in the View tag panel.
There are two types of View tag, Formatted Text and Image.
Formatted Text - View Tag to display the field value as formatted text using <div> tag with optional hyperlink. Properties:
| Format |
| None |
No formatting |
| Currency |
Display in currency format |
| Date/Time |
Display in date format |
| Number |
Display in number format |
| Percent |
Display in percent format |
| String |
Format the field value with specified string function or custom function.
Note: You can also enter your own VB/C# expression, substitute the field value by "{value}". For example, you can enter:
MyFormatStringFunction({value}) or MyFormatStringFunction({value}, MyArgs)
Of course, you must first put your function in the template or generated script or global code section under server events so it is available for use.
|
| Max Length (List page) |
Truncate the field value at specified max. length and append "..." to the end.
Note: This setting only applied to memo fields in list page and must be larger than 0 to take effect. |
| DIV Tag attributes |
| Style |
Bold - Display as Bold
Italic - Display as Italic
Align - Left/Center/Right/Justify. Align the data. |
| Custom Attributes |
Other custom attributes for the <div> tag. For example, you can enter "onmouseover='my_js_function();'". |
| Hyperlink |
| HREF field |
Display the field as hyperlink with the href attribute set to the value of this field. Can be the field itself. |
| Target |
_top/_parent/_self/_blank |
| Prefix |
- None (no prefix, relative path of url)
- http:// (prefix http:// added, absolute path of url)
- mailto: (prefix mailto: added, email link)
- ftp:// (prefix ftp:// added, ftp link)
- file:// (prefix file:// added, file link)
- news:// (prefix news:// added, newsgroup link) |
| Suffix |
Append the input string to the URL |
Image - View Tag to display as Image using <img> tag. The field should be a BLOB field or a field storing the path of the image.
| IMG Tag attributes |
| Width |
Specify the width of the image |
| Height |
Specify the height of the image |
| Alt |
Specify the alt attribute of the image tag |
| Custom Attributes |
Other custom attributes for the <div> tag. For example, you can enter "onmouseover='myjsfunction();'". |
| Resize |
Resize the image to above width and/or height on displaying the image.
Note: This features requires the Image Resize template extension and that the extension is enabled. (click Tools->Extension to enable) See Third-Party Tools for information about template extensions.
|
| Hyperlink (same as above) |
Edit Page

Properties
| Edit |
Show field in edit page |
| Title |
Title to be placed in title attribute of Edit Tag. (see section below) |
| Read Only |
Make the field read only in edit page |
| Edit Tag |
Form element for the field.
Use in Add/Copy/Edit/Search pages. (See below for details) |
You can either click the [Edit Tag] column and select a Edit Tag from the drop down box or click the icon on the [Edit Tag] panel toolbar to select. After selecting the Edit Tag, you can further setup its properties in the Edit Tag panel:
Edit Tags
Edit Tags are HTML forms elements for the field in Add/Copy/Edit/Search pages. All HTML form elements are supported:
| Text |
 |
<input type="text">
tag
Display the field as a textbox.
Size - size of the textbox
MaxLength - maximum input length of the textbox
Custom attributes - Other custom attributes for the tag
Validation - see section below
Use Lookup Table - enable Auto-Suggest and/or Auto-Fill feature by Ajax.
Auto-Suggest - With a lookup table, when the user type in the textbox, a dynamic dropdown list populated with data from the lookup table matching the user input will appear for user to select. If the data already exists, the user can easily select without typing the full text. If not, the user can still input as usual. To enable this feature, check [Use Lookup Table] and enter the lookup table info in the [Lookup Table] panel next to the [Edit Tag] panel. (See section below)
|
| Password |
 |
<input type="password">
tag
Display the field as a masked textbox.
Size - size of the textbox
MaxLength -= maximum input length of the textbox
Custom attributes - Other custom attributes for the tag
Validation - see section below |
| Radio |
 |
<input type="radio">
tag
Display the field as an option of a radio button list. You can enter the options
manually in the [User Value] panel next to the [Edit Tag] panel.
Custom attributes - Other custom attributes for the tag
Use lookup table - use an existing lookup table instead of user input value/label pairs for the radio buttons. To enable this feature, check this option and enter the lookup table info in the [Lookup Table] panel next to the [Edit Tag] panel. (See section below)
Repeat columns - specifies the no. of radio buttons per row
Validation - see section below |
| Checkbox |
 |
<input type="checkbox">
tag
Display the field as one or more option(s) of a checkbox list. You can enter the options
manually in the [User Value] panel next to the [Edit Tag] panel.
Custom attributes - Other custom attributes for the tag
Use lookup table - use an existing lookup table instead of user input value/label pairs for the checkboxes. To enable this feature, check this option and enter the lookup table info in the [Lookup Table] panel next to the [Edit Tag] panel. (See section below)
Repeat columns - specifies the no. of checkboxes per row
Validation - see section below
Note: The submitted values of the multi-selected checkboxes is a comma-separated string. Therefore you must use a string field
for checkbox list.
|
| Select |
 |
<select> tag
Display the field as a combobox (one selection) or a listbox (multiple selection). You can enter the options
manually in the [User Value] panel next to the [Edit Tag] panel.
Size - no. of options to show. If more that 1, the
selection list is shown as a listbox, otherwise it is shown as a
combobox.
Multiple: Check to enable multiple selection (listbox)
Note: The submitted values of the multi-selected listbox is a comma-separated string. Therefore you must use a string field
for listbox.
Custom attributes - Other custom attributes for the tag
Use lookup table - use an existing lookup table instead of user input value/label pairs for the checkboxes. To enable this feature, check this option and enter the lookup table info in the [Lookup Table] panel next to the [Edit Tag] panel. (See section below)
Use Ajax - specifies if Ajax is used to update the combobox.
Note: "Use Ajax" option does not support multiple selection.
Validation - see section below |
| TextArea |
 |
<textarea> tag
Display the field as a textarea.
Cols - no. of columns of the textarea
Rows - no. of rows of the textarea
Custom attributes - Other custom attributes for the tag
Use DHTML Editor - replace the textarea with a DHTML editor for editing the data as HTML.
Note: The DHTML Editor(s) requires newer version of browsers such as IE6+ or FF1+.
It is not developed by the author of ASP.NET Maker and no technical support
will be provided. (See Third-party Tools.)
Validation - see section below |
| File |
 |
<input type="file"> tag
Display the field as a file upload control. For BLOB fields or string fields only.
Size - size of the input tag (NOT file size)
Custom attributes - Other custom attributes for the tag
If the field is of BLOB (binary) data type, file is uploaded to the database. You can also store the information of the uploaded file in the following fields:
File type field - Recommended. Useful when you want to response to user browser the exact content type of the data.
File name field - Optional. Useful if you want to use the original filename.
Note: Do not specify file name field if you want IE to open the file automatically. (IE may fail to open non-image files retrieved from database properly.) Use file name field if you want IE to popup a File Download dialog for user to save the file with the filename specified in the file name field.
File size field - Optional. Stores the uploaded file size.
Image width field - Optional. For use with images only. Stores the width of the uploaded image.
Image height field - Optional. For use with images only. Stores the height of the uploaded image.
If the field of string type, file is uploaded to a subfolder relative to the application root.
Upload folder - the folder where the uploaded file will reside. If you do not enter a specific folder, all the uploaded files will be put in the global upload folder specified in the ASP.NET tab (see ASP.NET Setup).
Notes:
- Make sure that the Web server user have read/write access to the folder. Read Configuring Permissions.
- The path is relative to application root. Use slashes "/" as path delimiter, starts with "~". e.g. If the application root of your website is C:\Inetpub\wwwroot\demo and you enter "~/uploads/folder1" in this textbox, the folder for the uploaded files will be C:\Inetpub\wwwroot\demo\uploads\folder1. If you are not sure which folder is application root, please read Creating Virtual Directories in IIS.
Resize image - Optionally resize the image to resize width and/or height.
Resize width - the width of the resized image
Resize height - the height of the resized image
Note: This features requires the Image Resize template extension and that the extension is enabled. (click Tools->Extension to enable) See Third-Party Tools for information about template extensions.
Validation - see section below |
| Hidden |
 |
<input type="hidden"> tag
Hide the field with a hidden form element.
Note: This is different from de-selecting the field in the [Edit] column. If a field is de-selected, no code will be generated for the field in the Edit page and the field will not be updated. With a hidden form element the field is not seen but it may still get updated.
Custom value - by default the 'value' attribute contains the field value, custom value is used to update the field with an other value when a record is updated using the Edit page.
Custom attributes - Other custom attributes for the tag
Notes:
- Custom value is used in Edit page only. It cannot be used with Read-only fields, User ID fields and Detail fields(Foreign key fields)
- In Add page, if a default value is specified (see section below), hidden form element will also be used but the 'value' attribute will contain the default value. If default value is not specified, the field will be displayed as a normal textbox.
|
Using User Values for Edit Tag (Radio/Checkbox/Select)
For Radio/Checkbox/Select Edit Tags, the default option values are user input values, you can enter as many value/label pairs as you want in the [User Values] panel next to the [Edit Tag] panel.
Note: For boolean fields, if you use Radio Edit Tag with User Values, the first value/label should be for True and the second for False.
Using Lookup Table for Edit
Tag (Text/Radio/Checkbox/Select)
In real world applications, the option values usually come from a lookup table in the database. ASP.NET Maker make it very simple to use lookup values for key field values, simple click [Use Table], the [Lookup Table] panel will replace the [User Values] panel, select the following properties:

| Table name |
The lookup table to be linked to |
| Link field |
The field to be used as the value of an option (for Radio/Checkbox/Select only). This field is usually the primary key of the lookup table. |
| Display field #1 |
The field in lookup table to be used as the label of an option. (If auto suggest textbox, only string fields will be selectable.) |
| Display field #2 |
Optional. Another field in lookup table to be included in the label of an option. (If auto suggest textbox, only string fields will be selectable.) |
| Order By |
Optional. Used to sort the options. |
| Asc/Desc |
Optional. Sorting order. |
| Distinct |
Optional. Unique records only. (for Radio/Checkbox/Select only) |
| Filter |
WHERE clause to filter options from the table. |
| Parent field |
Optional. Available for Select or Text Edit tag only. Specify the parent selection list
for current selection list or textbox. When the parent selection list is changed, the available options in current selection list or the value of the current textbox will be changed accordingly.
|
| Filter Field |
Optional. Available for Select tag only. When the parent selection list changes, only
records with a Filter Field value matching the selected value of the
parent selection list will be shown.
|
| Allow Add |
Optional. If enabled, the user will be allowed to add an option to the selection list.
Notes:
- Review your lookup table design before using this option. The option works best if you there is only one display field and the link field (primary key) is an autoincrement field. In that case the user only need to fill in a textbox and the option is added. But if the link field (primary key) is not an auto-increment field, the user will need to enter the link field value which the user may not know.
- The user will be asked to enter the link field and the display field(s) only. If the lookup table has other NOT NULL fields other than the link field and display field(s), the new option cannot be added. However, you can define default values for these fields in the database (not in ASP.NET Maker).
- From ASP.NET Maker 7, this feature also work with child selection list Dynamic Selection List. The filter field value also be added according to the selected option of the parent selection list.
- This feature is implemented using Ajax, newer version of browsers such as IE6+/FF1+ is required.
- From ASP.NET Maker 7, adding fields other than the link field, display fields and filter field is allowed. Click the [...] button and select additional fields in the lookup table. However, please note that this feature is designed for adding a lookup value on-the-fly, it is NOT meant to replace the normal full-featured add form of the lookup table. You should choose as few fields as possible. File upload is not supported. Also, note that the add option form for each lookup table is shared among all fields (possibly in different tables) using the same lookup table. If you change the fields to be added to the lookup table, the shared add option form will affect other fields as well.
|
| Auto-Fill |
Optional. If enabled, the script fills the related fields for your automatically.
For example, when you select a product number (which is a lookup field using the product table as its lookup table), it will fill product price textbox for you. The required conditions are:
- the current field has a [Parent field] in the lookup table settings
- the parent field is setup as a combobox or radio buttons (That is, one selection only, or in other words, the parent field uses Select Edit tag with [Multiple] option DISABLED, see description for Select Edit tag below.)
- the parent field uses the same lookup table as the current field
If these conditions are met, when the user changes the parent combobox, the Ajax script will try to lookup another field value (specified by [Display field #1] of the lookup table for the current field) from the record found according to the selected option of the combobox, and the value will be filled into the textbox automatically.
ASP.NET Maker can setup these conditions automatically, simply click the [...] button and select the source fields for those fields to be auto-filled:

With this setup, when you select a product number from combobox, the script know the product ID from the option value, so it can use the ID to locate the product from the same lookup table (your product table) and retrieve other field values such as the product unit price and fill those fields.
Note: Before using Auto-Fill, review your database design, consider database normalization, in many cases you do not need to copy the values in the first place. You can view the other field values by creating a query/view joining the current table with the lookup table using the parent field as linked field.
|
ASP.NET Maker supports Dynamic Selection Lists in which child lookup fields' selection list
options change dynamically based on option selected in the parent selection
list. To setup child lookup fields, click the [Child lookup fields...] button and the following setup form will be displayed:

Validation (for add/copy/edit/search pages)
The data input for each field can be validated using client-side JavaScript.
| Validate |
Supported validation formats are:
Integer, Float, Range, Date(yyyy/mm/dd), Date(mm/dd/yyyy), Date(dd/mm/yyyy),
Time(hh:mm:ss), Email, Credit card, GUID, US phone number, US zip code, US social
security number
Notes:
- Other than "/", the date separator of the validation format can also be "-" or ".", depending on the default date format setting in ASP.NET Setup page.
- From ASP.NET Maker 7+, you can add your own JavaScript functions for validation. The JavaScript function must accept one argument (the value) and return true (valid value) or false (invalid value). You can add your function names (comma separated) in the following registry key:
HKEY_CURRENT_USER\Software\ASPNETMaker\<Version>\Settings\General
Value: CustomValidationFunctions
e.g. You can enter "myValidateFunction1,myValidateFunction2". Of course, you also need to include your JavaScript functions in the generated scripts or in the template so it is available for use.
|
| Use popup calendar |
Check this option to use a visual date picker instead of manual input.
Notes:
- This option is only available for the date validation formats: Date(yyyy/mm/dd), Date(mm/dd/yyyy), Date(dd/mm/yyyy).
- The popup calendar requires IE 5+ or FF 1+. It is not developed by the author of ASP.NET Maker and no technical support will be provided. (See Third-party Tools.)
|
| Required |
Check this checkbox if the field is mandatory |
| Error Message |
Enter the error message to popup if error occurs |
| Check Duplicate |
Specify whether to check duplicated values for the field.
If the field is an unique indexed field, ASP.NET Maker will generate server side codes to check duplicate values automatically even this option is not selected. This option is useful when you want to check a non unique indexed fields for duplicated values.
Note: From ASP.NET Maker 7+, the validation is done on both Add and Edit pages.
|
Add Page

Properties
| Add |
Show field in add page |
| Default Value |
Default value for field (for adding new record only) . Must be a valid VBScript expression. (If it is a string, must be double quoted.) |
Multi-Update Page

Properties
| Multi-Update |
Show field in Multi-Update page
Note: If a field is selected, it will be included in the Multi-Update page. In the generated Multi-Update page, there is a checkbox for each field, the field will only be updated if the checkbox is checked so users can update only the checked fields without affecting values of the other unchecked fields.
|
Advanced Search Page

Properties
| Search |
Show field in Advanced Search page (Note: NOT related to Quick
Search) |
| Search Opr 1 |
Search operator #1 for the field. Used in Advanced Search or Extended Quick Search. |
| Search Opr 2 |
Search operator #2 for the field. Used in Advanced Search or Extended Quick Search.
Notes:
- This second search operators will be useful when you may have 2 criteria for the field when searching. You can also select AND/OR to relate the 2 criteria.
- ASP.NET Maker (5+) supports "BETWEEN" search operator. If you want to use it, select "BETWEEN" as the first search operator. Since "BETWEEN" requires 2 search criteria, when it is used, the second search operator will be ignored.
|
|