Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sending array from com to asp.
Message
De
27/07/2000 15:03:04
 
 
À
19/07/2000 10:42:45
Information générale
Forum:
Visual FoxPro
Catégorie:
Applications Internet
Divers
Thread ID:
00394332
Message ID:
00397800
Vues:
19
You have to pass the array into the COM object.
In the Init() of the COM class, add this line to make sure the VFP object knows to treat parameters by reference.
SET UDFPARMS TO REFERENCE
Then make the call from the ASP page like this: (VBScript)

** ASP code
Set oCOM = Server.CreateObject("myvfpdll.myclass")
Dim aArray(0)
oCOM.DoSomething aArray
** aArray now has 4 elements

** VFP code
** myclass.DoSomething
LPARAMETERS taArray
EXTERNAL ARRAY taArray
DIMENSION taArray(4)
taArray[1] = "this"
taArray[2] = "is"
taArray[3] = "a"
taArray[4] = "test"

The ASP page (using VBScript, at least) will still treat the array as 0 based, but it will be (Row,Col) as in VFP, not (Col,Row)
Insanity: Doing the same thing over and over and expecting different results.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform