Settings that affect the appearance and behavior of columns whose edit style is Edit.
Column controls
DataWindow .NET dot notation:
(( SimpleEdit) colname.EditStyle).property [C#] CType(colname.EditStyle, SimpleEdit).property [Visual Basic]
Describe and Modify argument:
"columnname.Edit.property { = value }"
DataWindowSyntaxFromSql:
Column ( Edit.property = value )
Parameter |
Description |
---|---|
columnname |
The column with the Edit edit style for which you want to get or set property values. You can specify the column name or a pound sign (#) and the column number. |
property |
A property for the column’s Edit style. Properties and their settings are listed in the table below. The table identifies the properties you can use with DataWindowSyntaxFromSql. |
value |
The value to be assigned to the property. For most Edit properties, you cannot specify a DataWindow expression. The exception is Edit.Format. |
Property for Edit |
Value |
---|---|
AutoHScroll |
Whether the edit control scrolls horizontally automatically when data is entered or deleted. Values are:
You can use AutoHScroll with DataWindowSyntaxFromSql. The setting applies to all the columns in the generated syntax. |
AutoSelect |
Whether to select the contents of the edit control automatically when it receives focus. Values are:
You can use AutoSelect with DataWindowSyntaxFromSql. The setting applies to all the columns in the generated syntax. |
AutoVScroll |
Whether the edit box scrolls vertically automatically when data is entered or deleted. Values are:
You can use AutoVScroll with DataWindowSyntaxFromSql. The setting applies to all the columns in the generated syntax. |
Case |
The case of the text in the edit control. Values are:
|
CodeTable |
Whether the column has a code table. Values are:
|
DisplayOnly |
Whether the column is display only. Values are:
For conditional control over column editing, use the Protect property. |
FocusRectangle |
Whether a dotted rectangle (the focus rectangle) will surround the current row of the column when the column has focus. Values are:
You can use FocusRectangle with DataWindowSyntaxFromSql. The setting applies to all the columns in the generated syntax. |
Format |
(exp) A string containing the display format of the edit control. The value for Format is quoted and can be a DataWindow expression. |
HScrollBar |
Whether a horizontal scroll bar displays in the edit control. Values are:
|
Limit |
A number specifying the maximum number of characters (0 to 32,767) that the user can enter. 0 means unlimited. |
Name |
A string whose value is the name of the predefined edit style associated with the column. Named styles are defined in the Database painter and can be reused. Specifying a name that has not been previously defined associates the name with the column but does not define a new edit style. |
NilIsNull |
Whether to set the value of the edit control to null when the user leaves it blank. Values are:
|
Password |
Whether to assign secure display mode to the column. When the user enters characters, they display as asterisks (*). Values are:
If you change the Password property, you should also change the Format property to display the results you want (for example, *****). |
Required |
Whether the column is required. Values are:
|
Style |
(Describe only) Returns the edit style of the column. Painter: EditStyle option. |
UseEllipsis |
Whether an ellipsis (three dots) displays when a column with the Edit edit style contains character data that is too long for the display column in the DataWindow. The ellipsis does not display when the column has focus. Values are:
The property is ignored if you:
The UseEllipsis DataWindow object property is not supported in Web Forms applications. |
ValidateCode |
Whether the code table will be used to validate user-entered values. Values are:
|
VScrollBar |
Whether a vertical scroll bar displays in the line edit. Values are:
|
Select the control and set values in the Properties window, Behavior category, when EditStyle is Edit.
In DataWindow .NET, you can use the SimpleEdit class to set Edit style properties using dot notation. See the description of the SimpleEdit class in the online Help in Visual Studio .NET for a complete list of properties. Some properties have different names and are set differently. For example, the Case DataWindow object property is equivalent to the CharacterCasing property in DataWindow .NET, which uses an enumeration.
[Visual Basic] dw1.emp_name.Edit.Required = false
setting = dw1.Describe("emp_name.Edit.AutoHScroll")
dw1.Modify("emp_name.Edit.Required=no")
dw1.Modify("col1.Edit.UseEllipsis=Yes")