Skip to content

File_Field_Current_Value - DataDictionary

Get/sets the current value of a foreign table column

Type: Property
Access: Read/Write
Data Type: String
Parameters: None

Parameters

Parameter Type Description
iFile Integer Number of the table in the current filelist
iField Integer Number of column iField in the table

Syntax

Property String File_Field_Current_Value
Access Type Syntax
Read Access: Get File_Field_Current_Value to StringVariable
Write Access: Set File_Field_Current_Value to StringVariable/Value

Description

These messages are used to retrieve and change a foreign table column's value. Get Field_Current_Value is used to retrieve the current value of a non-foreign column. This message is used frequently.

Sample

Get File_Field_Current_Value of hoDD File_Field Customer.Name to sName
Set File_Field_Current_Value of hoDD File_Field Customer.Name to sName

You will note that many of the samples use the file buffer to directly obtain the value of a column (e.g. Move Customer.Name to sName). This is discussed in detail in Understanding File Buffers and DDO Field Buffers.

The set version of this message is used to change the current value of a foreign column. You change the value of a DDO column in preparation for a save. When you change a column's value, you must also change its changed-state. This can be done with File_Field_Changed_State.

Set File_Field_Current_Value of hoDD File_Field Customer.Name to sName
Set File_Field_Changed_State of hoDD File_Field Customer.Name to True

'Set File_Field_Changed_Value' performs both of these operations and is usually used for this purpose. Therefore, 'Set File_Field_Current_Value' is rarely used.

Important

If a save operation is not changing the value of a changed column, check if you are using File_Field_Current_Value instead of File_Field_Changed_Value. This is a common mistake.

File and File_Field Interfaces

Many of the DataDictionary methods contain a two variants of the same message: Field_Message and File_Field_Message. For a complete description of these messages please refer to The Field and File_Field DD Interfaces.

The Field_ version of a message must use the keyword FIELD to identify the Table.Column name. The File_Field_ version must use the keyword FILE_FIELD to identify the Table.Column name. These should never be mixed!

// When using Field_ message use the FIELD keyword
Get Field_Current_Value of hoDD Field Customer.Name to sName
Set Field_Current_Value of hoDD Field Customer.Name to sName

// When using the File_Field_ message use the FILE_FIELD keyword
Get File_Field_Current_Value of hoDD File_Field Customer.Name to sName
Set File_Field_Current_Value of hoDD File_Field Customer.Name to sName
Col 1 Col 2
Note: This property does not apply to text and binary columns. See DDOs and Extended Field Support for more information.

See Also

File_Field_Current_UCAValue | Understanding File Buffers and DDO Field Buffers | RefTable | The File_Field and Field Keywords