Name | CNSQuery_RemoveField |
---|
Description | This function Removes a Field from a Table. The first parameter is the Name of a Table Occurrence of the Table to Remove the Field from. If you do not specify this parameter, CNS Query will use Get(LayoutTableName) to get the Current Layout TO and Remove the Field from that TO. The second parameter is the Name of the Field to Remove. By default, CNS Query will check to make sure the TO Name and the Field Name you specify exist before attempting to Remove the Field. If you already know for sure that the TO Name and the Field Name exist, you can pass True as the third and fourth parameters.
Note: In FileMaker Pro 8.5 and above, you must insert a “Pause” Script Step after using this function in order for the Field to be Removed.
|
---|
Return Type | Text |
---|
Format | CNSQuery_RemoveField ( TOName ; FieldName ; SkipTONameCheck ; SkipFieldNameCheck ) |
---|
Required Parameters | TOName The Name of the Table Occurrence to Remove the Field from. Specify “” to use the Current Layout TO. In FileMaker Pro 11 and above, you can optionally specify the Database Filename (without the “.fp7” extension) containing the TO in the format “FileName.TOName”.
FieldNameThe Name of the Field to Remove.
|
---|
Optional Parameters | - SkipTONameCheck
If True, CNS Query will not check to make sure the TO Name you specified actually exists before attempting to Remove the Field.
- SkipFieldNameCheck
If True, CNS Query will not check to make sure the Field Name you specified actually exists before attempting to Remove the Field.
|
---|
Examples | - Example 1
Removes the "MyField" Field from the "MyTable" Table. CNSQuery_RemoveField( "MyTable" ; "MyField" )
- Example 2
In FileMaker Pro 11 and above, use this form to Remove a Field from a Table in a separate, open Database file. CNSQuery_RemoveField( "AnotherFile.MyTable" ; "MyField" )
|
---|