General information
Category:
COM/DCOM and OLE Automation
Title:
VFP COMM will not support an array
Scenario 1: I create an object with an array property, it works fine.
Scenario 2: I create the same object as a com object, the array is no longer an array.
This code can be run two ways to show what I mean:
**************************** PRG CODE ****************************
public o, mm
*: o = createobject('vfpapptier.vfpdataobjectvisual')
o = createobject('vfpdataobjectvisual')
mm = o.GetTheCursor()
DEFINE CLASS vfpdataobjectvisual AS custom
*: DEFINE CLASS vfpdataobjectvisual AS custom OLEPUBLIC
Name = "vfpdataobjectvisual"
DIMENSION ArrayCursor[1]
DIMENSION ArrayAnother[3,1]
PROCEDURE getthecursor
create cursor cTest (FieldOne c(10))
insert into cTest (fieldone) values ('One')
insert into cTest (fieldone) values ('Two')
insert into cTest (fieldone) values ('Three')
dimension this.ArrayCursor(reccount(),1)
copy to array this.ArrayCursor
use in cTest
store 'John' to this.ArrayAnother
return this
ENDPROC
ENDDEFINE
******************* ENDOF PRG CODE ********************************
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only