Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
EVALUATE('THISFORM.lAccessed3 = .T.') not working????
Message
From
19/10/1999 18:13:13
Jorge Haro
Independent Consultant
Juarez, Mexico
 
 
To
19/10/1999 18:10:50
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00277939
Message ID:
00278525
Views:
24
Yea I read it, pretty cool huh?

>Jorge:
>Again, thank you.
>FYI, there was one more solution. See reply from Kenneth Downs.
>Regards,
>
>Mal
>
>
>>Yea, that was it, glad to help.
>>
>>>Joege:
>>>Forget my previous reply ... You were right: IT WORKED!
>>>Instead of EVAL('&m'), I guess you were saying just use &m.
>>>
>>>m = "THISFORM.lAccessed3 = .T."
>>>&m
>>>
>>>THIS WORKS!!
>>>
>>>Thanks Jorge
>>>
>>>Mal
>>>
>>>>I think what you're doing here is evaluating the expression THISFORM.lAccessed3 = .T. like in
>>>>
>>>>
>>>>
>>>>if THISFORM.lAccessed3 = .T.
>>>>..
>>>>endif
>>>>
>>>>
>>>>
>>>>In other words you are asking Is THISFORM.lAccessed3 = .T.?, so when evaluated it tells you if it is or of it isn't, try this:
>>>>
>>>>? eval("THISFORM.lAccessed3 = .T.")
>>>>
>>>>It should return .t. or .f., but no data is changed. Now, to do what you want you just need:
>>>>
>>>>&m
>>>>
>>>>"m" will be substituted at runtime with THISFORM.lAccessed3 = .T., and will be executed as expected, hope I was clear enough
>>>>
>>>>
>>>>
>>>>>
>>>>>Actually, this is what I'm trying to do.
>>>>>
>>>>>m = ALLTRIM('lAccessed' + '3')
>>>>>*need to do this becuase the '3' changes depending on what the form number it's executed from (in this case it's form #3).
>>>>>
>>>>>m = 'THISFORM.' + m + ' = .T.'
>>>>>
>>>>>?m .... && shows THISFORM.lAccessed3 = .T.
>>>>>
>>>>>EVALUATE('m') does not change the lAccess3 to .T.
>>>>>
>>>>>What am I missing? It works for procedures and functions;
>>>>>i.e. if m equaled THISFORM.DoChanges(3).
>>>>>
>>>>>As always, thank you for your help.
>>>>>
>>>>>Mal
Previous
Reply
Map
View

Click here to load this message in the networking platform