Product Documentation

c-treeDB API for C# - Developers Guide

Previous Topic

Next Topic

CTRecord.SetFieldValue

Syntax

void SetFieldValue(int FieldNumber, bool value)

void SetFieldValue(String FieldName, bool value)

void SetFieldValue(int FieldNumber, int value)

void SetFieldValue(String FieldName, int value)

void SetFieldValue(int FieldNumber, uint value)

void SetFieldValue(String FieldName, uint value)

void SetFieldValue(int FieldNumber, long value)

void SetFieldValue(String FieldName, long value)

void SetFieldValue(int FieldNumber, double value)

void SetFieldValue(String FieldName, double value)

void SetFieldValue(int FieldNumber, string value)

void SetFieldValue(String FieldName, string value)

void SetFieldValue(int FieldNumber, byte[] value)

void SetFieldValue(String FieldName, byte[] value)

void SetFieldValue(int FieldNumber, CTBlob value)

void SetFieldValue(String FieldName, CTBlob value)

void SetFieldValue(int FieldNumber, CTNumber value)

void SetFieldValue(String FieldName, CTNumber value)

void SetFieldValue(int FieldNumber, CTDate value)

void SetFieldValue(String FieldName, CTDate value)

void SetFieldValue(int FieldNumber, CTTime value)

void SetFieldValue(String FieldName, CTTime value)

void SetFieldValue(int FieldNumber, CTDateTime value)

void SetFieldValue(String FieldName, CTDateTime value)

void SetFieldValue(int FieldNumber, DateTime value)

void SetFieldValue(String FieldName, DateTime value)

void SetFieldValue(int FieldNumber, CTMoney value)

void SetFieldValue(String FieldName, CTMoney value)

void SetFieldValue(int FieldNumber, CTCurrency value)

void SetFieldValue(String FieldName, CTCurrency value)

Parameters

  • FieldNumber [in] - The field number.
  • FieldName [in] - The field name.
  • value [in] The value to store in the field.

Description

Sets the field contents. The suggested methods for setting field values are as follows:

SetFieldValue(String fieldName, anytype Value);

and

SetFieldValue(int fieldNumber, anytype Value);

  • anytype means that these methods are overloaded to accept the needed types as shown above under Syntax.
  • Either fieldName or fieldNumber can be used to specify the field.

For example, to set a filed to a Bool value of true, use either:

SetFieldValue(fieldName, true);

or

SetFieldValue(fieldNumber, true);

Return

None.

See Also

GetFieldValue()

TOCIndex