OrderSpec.OrderAdd Method | |
Adds order information from an existing index file to the OrderSpec object and associates this OrderSpec object with the DBFileSpec object used for instantiation.
Namespace:
VO
Assembly:
VORDDClasses (in VORDDClasses.dll) Version: 2.21
Syntax VIRTUAL METHOD OrderAdd(
oFS,
uOrder
) AS USUAL CLIPPER
[ClipperCallingConventionAttribute(new string[] { ... })]
public virtual Usual OrderAdd(
Usual oFS = default,
Usual uOrder = default
)
Request Example
View SourceParameters
- oFS (Optional)
- Type: Usual
A string or filespec object that specifies the full path to the index file or a FileSpec object of the index file. - uOrder (Optional)
- Type: Usual
The order name or numeric position if using multi-order files.
Return Value
Type:
Usual
TRUE if successful; otherwise, FALSE.
Examples
The following examples illustrate several different types of orders you can add:
1
2oDB := DBFileSpec{, "DBFCDX"}
3IF oDB:Find()
4oOrd1 := OrderSpec{oDB}
5oOrd2 := OrderSpec{oDB}
6oOrd3 := OrderSpec{oDB}
7oOrd1:OrderAdd("C:\TEST\customer.cdx", "FirstName")
8oOrd2:OrderAdd("C:\TEST\customer.cdx", "LastName")
9oOrd3:OrderAdd("C:\TEST\customer.cdx", "CustNum")
10ENDIF
11
12oDB := DBFileSpec{, "DBFNTX"}
13IF oDB:Find()
14oOrd1 := OrderSpec{oDB}
15oOrd2 := OrderSpec{oDB}
16oOrd3 := OrderSpec{oDB}
17oOrd1:OrderAdd("C:\TEST\cust1.ntx")
18oOrd2:OrderAdd("C:\TEST\cust2.ntx")
19oOrd3:OrderAdd("C:\TEST\cust3.ntx")
20ENDIF
See Also