Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Decorator (Wrapper) classes
Message
 
À
03/05/1998 19:24:19
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00096626
Message ID:
00096630
Vues:
14
Dan,

You're trying to pass an element, not the array. Get rid of the [1,1] in your method call.

>I'm adapting Yair Alan Griver's example of a decorator class, from the May 1998 issue of FoxPro Advisor, for another library file, Graphics Server. One of the commands I'm trying to wrap, passes an array by reference. When I run it I'm getting the following error message:
>Function argument value, type, or count is invalid (Error 11)
>
>I'm using the syntax below:
>oGraph.GSDataAmp(ALEN(gaData,1),ALEN(gaData,2),@gaData[1,1])
>
>The actual method code is:
>PROCEDURE GSDataAmp
> LPARAMETERS tnRows,tnColumns,taData
> LOCAL lnRetVal
> lnRetVal = -1
> IF PARAMETERS() = 3
> lnRetVal = (GSDataAmp(tnRows,tnColumns,@taData[1,1]))
> ENDIF PARAMETERS() = 3
> RETURN (lnRetVal)
>ENDPROC
>
>What I'm doing wrong and how do I correct it?
>
>Thanks,
>
>Dan Rhymes
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform