Is it possible to work with pointers (a la macro substitution in VFP) in VBScript? I'm trying to create some generic scripts to handle data processing and need this ability. As an example:
I want to loop through the Fields collection of a recordset. For each item in the Fields collection, I want to programmatically create a variable by prepending "str" to Fields.Name. Then I want to assign that variable the Fields.Value property. In VFP, it would look like:
oConnection = CreateObject("adodb.connection")
oConnection.Open("Source")
oRecordSet = CreateObject("adodb.recordset")
oRecordSet.Open("Select * From Plan!Inhouse Order By Latiname", oConnection)
For Each Item In oRecordSet.Fields
strTemp = "str" + Item.Name
* Substitute the value of strTemp and assign the fields value
&strTemp = Item.Value
EndFor
At this point, I would have a set of variables available to me with the proper value assigned. Any help or ideas are as always appreciated.
TIA, Bill
Oct 31 = Dec 25