AOTTableFieldList.addDate(String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Adds a new field of the date type to the list of fields for the current table.
public:
virtual void addDate(System::String ^ _name);
[Microsoft.Dynamics.BusinessPlatform.SharedTypes.InternalUseOnly]
public virtual void addDate (string _name);
[<Microsoft.Dynamics.BusinessPlatform.SharedTypes.InternalUseOnly>]
abstract member addDate : string -> unit
override this.addDate : string -> unit
Public Overridable Sub addDate (_name As String)
Parameters
- _name
- String
The name of the field to add.
- Attributes
-
Microsoft.Dynamics.BusinessPlatform.SharedTypes.InternalUseOnlyAttribute
Remarks
If the supplied name coincides with an existing field in the field list, an integer is appended to the name of the new field to make the field name unique. The developer must make sure that the name is not a reserved word; the method will not throw an error if a reserved word is specified. You can use the AOTfindChild method to determine whether a field name is already being used.
The following code example adds the NewDate field, which is of the date type, to the list of fields for the TutorialJournalName table.
AOTTableFieldList tfl = infolog.findNode(
'\\Data Dictionary\\Tables\\TutorialJournalName\\Fields');
if (!tfl.AOTFindChild('NewDate'))
{
tfl.addDate('NewDate');
}