Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Clone a cursor and its SET KEY.
Message
 
 
To
30/08/2003 12:24:38
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00824799
Message ID:
00824812
Views:
20
Hi Fabio,

I would also expect that SET("KEY") function would return SET KEY expression in the format that can be eaily reused in another SET KEY command. In addition, in the case of DATE expression returned values are ambiguous because they depends on SET DATE and other settings.
You can post ER to VFP WIsh list but for now you will've to deal with it.

>Hi,
>
>i try to write a generic clone function for a workarea.
>
>For ORDER it is ok
>For FILTER it need a slow macro, but i can
>For SET KEY problem occurs.
>
>If expression index is logical,date,datetime and character,
>SET("KEY") return a incomplete string.
>This can to be ambiguous.
>
>Example:
>
>CREATE CURSOR MyTest ( fDate D DEFAULT DATE() UNIQUE)
>APPEND BLANK
>SET ORDER TO 1
>SET KEY TO DATE()
>? SET("KEY")         && i aspect {99-99-9999},{99-99-9999}
>
>CREATE CURSOR MyTest ( fDate C(10) default DTOC(DATE()) UNIQUE)
>APPEND BLANK
>SET ORDER TO 1
>SET KEY TO DTOC(DATE())
>? SET("KEY")         && i aspect '99-99-9999','99-99-9999'
>
>
>
>My aspect result is direct useful for EVALUATE().
>
>EXAMPLE:
>
>m.Key1=EVAL(SET("KEY",1))
>
>
>Why SET("KEY") command is incomplete ?
>
>
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform