Methods | Properties |
We know that each
individual piece of information in a record is called field and field object
corresponds to a column in the Recordset.Field collection Contains all the Field
objects of a Recordset or Record object.ie Fields collection contains an entry
for each field in the current record.
Asp Field Collection – Methods
Method | Syntax | Description |
Append | objFields.Append
(Name, Type, Size, Attrib, Value) |
creates
and adds a Field object to the collection.Name is the name of new field,Type is the data type of the new field. Size,Attrid,Value are optional.Size represents the defined size, in characters or bytes, of the new field,Value is a Variant that represents the value for the new field. If not specified, then the field is appended with a null value. |
Delete | objFields.Delete
(Field) |
deletes
an object from the Fields collection.The field parameter can be the name of the Field object or the ordinal position of the Field object itself. |
Update | objRecord.Fields.Update | this finalizes
any additions or deletions. |
CancelUpdate | objRecord.Fields.CancelUpdate | Cancels
any changes made to the Fields collection of a Record object, before calling the Update method. |
Asp Field Collection – Properties
Property | Syntax | Description |
Count | objFields.Count | Indicates
the number of objects in a collection.Since numbering for members of a collection begins with zero, you should always code loops starting with the zero member and ending with the value of the Count property minus 1. |
Item | objFields.Item
(Index) |
return a
specific member in a collection. |