Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
UDF and FP Function, partiality
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
FoxPro 2.x
Divers
Thread ID:
00677396
Message ID:
00677864
Vues:
21
Sorry I messed up the quotes in retyping:

m.typefilt = "INLIST(a09macct.typegroup, 'CASH', 'BANK')"
m.typefilt = "typgrp(a09macct.typegroup, 'CASH', 'BANK')"

>The both lines give "syntax error".
>m.typefilt = "INLIST(a09macct.typegroup, "CASH", "BANK")
>m.typefilt = "typgrp(a09macct.typegroup, "CASH", "BANK")
>
What's your actual code?
>
>
>>Hi all
>>
>>I didn't know how to name this thread, thus an odd one.
>>
>>Here is my code from the init of the screen:
>>
>>m.typefilt = "INLIST(a09macct.typegroup, "CASH", "BANK")
>>
>>
>>this is the code in the valid of an invisible button:
>>
>>invhelp(paras, ..., m.typefilt)
>>
>>
>>this is the code in invhelp():
>>
>>PARAMETERS m.zparas, ..., m.zfilter
>>...
>>IF m.zfilter # "NOCHANGE"
>>   SET FILTER TO &zfilter.
>>ENDIF
>>...
>>
>>
>>
>>This above works well. Now I ended up with a requirement wherein the typegroup can contain a word and not necessary at the start of the field. So I wrote a udf to tackle the same which just does a $ for each and every parameters passed to the UDF so the inv. button call changed to:
>>
>>Here is my code from the init of the screen:
>>
>>m.typefilt = "typgrp(a09macct.typegroup, "CASH", "BANK")
>>
>>
>>This above started giving me errors so I changed the inv. button code to:
>>invhelp(paras, ..., &typefilt.)
>>
>>
>>
>>
>>Great works for a screen, but the second screen gives an error, why?
>>
>>Because in the second screen the same inv. buttons valid codes interprets the string m.typefilt and sends either a .T. or .F. to the invhelp() function.
>>
>>
>>Please can anybody shed some light on what might be happening. Switch back to INLIST and all previous code works.
Regards
Bhavbhuti
___________________________________________
Softwares for Indian Businesses at:
http://venussoftop.tripod.com
___________________________________________
venussoftop@gmail.com
___________________________________________
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform