Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problem with Alias does not exist
Message
 
 
To
25/04/2022 15:49:22
John Ryan
Captain-Cooker Appreciation Society
Taumata Whakatangi ..., New Zealand
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Miscellaneous
Thread ID:
01684254
Message ID:
01684264
Views:
30
Hi John,

Ok; what you are saying makes sense. But what puzzles me is why I don't get the error on my system?
I can change the code to your suggestion but first I would like to duplicate the problem on my side.
Thanks.

>Hi Dmitry,
>
>>> cControlSource = ALLTRIM( this.control_source )
>>> IF EVALUATE( cControlSource ) == OLDVAL( cControlSource )
>>> RETURN .T.
>>> ENDIF
>>>
>
>The parameters for OLDVAL are
>
>
OLDVAL(cExpression [, cTableAlias | nWorkArea])
>
>where cExpression would be your field name and cTablealias the cursor or table-
>
>So that to pass a controlsource like myalias.myfield you'd be looking to use getwordnum() or similar to peel out cTablealias and field name/s separately.
>
>
if evaluate(cControlsource)=iif("." $ cControlsource,oldval(getwordnum(cControlsource,2,"."),getwordnum(cControlsource,1,".")),oldval(cControlsource))
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform