Gets and formats data whose type is String from the specified buffer of a DataWindow control or DataStore object.

Applies to

DataWindow type

Method applies to


DataWindow control, DataWindowChild object, DataStore object



string dwcontrol.GetItemFormattedString ( long row, integer column 
   {, DWBuffer dwbuffer, boolean originalvalue } )
string dwcontrol.GetItemFormattedString ( long row, string column 
   {, DWBuffer dwbuffer, boolean originalvalue } )




A reference to a DataWindow control, DataStore, or child DataWindow.


A value identifying the row location of the string data.


The column location of the data. The datatype of the column must be String. Column can be a column number or a column name. The column number is the number of the column as it is listed in the Column Specification view of the DataWindow painter -- not necessarily the number of the column in the Design view.

To get the contents of a computed field, specify the name of the computed field for column. Computed fields do not have numbers.

dwbuffer (optional)

A value of the dwBuffer enumerated datatype identifying the DataWindow buffer from which you want to get the data. For a list of valid values, see DWBuffer.

originalvalue (optional)

A boolean indicating whether you want the original or current values for row and column:

  • True -- Returns the original values (the values initially retrieved from the database).

  • False -- (Default) Returns the current values.

If you specify dwbuffer, you must also specify originalvalue.


Use GetItemFormattedString in place of GetItemString when you want to return the value from a column in its current display format. This is especially useful if the column in question is not a computed column.


These statements set LName to the current string in the primary buffer for row 3 of in the column named emp_name in the DataWindow dw_employee. The retrieved value is formatted with the display format of the column:

String LName
LName = dw_employee.GetItemFormattedString(3, "emp_name")

See also