Hi Karl,
Thanks, apparently the problem is that
? ValType(Evaluate("NIL"))
returns "O"
while
? ValType(NIL)
returns "U" as expected. Will log this right now, thanks!
MEMVARs, PUBLICs etc.
MEMVARs, PUBLICs etc.
Chris Pyrgas
XSharp Development Team
chris(at)xsharp.eu
XSharp Development Team
chris(at)xsharp.eu
-
- Posts: 774
- Joined: Wed May 17, 2017 8:50 am
- Location: Germany
MEMVARs, PUBLICs etc.
Hi Robert,
i´ve noticed that the behaviour of a PUBLIC and PRIVATE RELEASE has changed. Now both are "destroyed" like Foxpro does. To be sure, i´m asking if this behaviour is intended ?
regards
Karl-Heinz
i´ve noticed that the behaviour of a PUBLIC and PRIVATE RELEASE has changed. Now both are "destroyed" like Foxpro does. To be sure, i´m asking if this behaviour is intended ?
regards
Karl-Heinz
-
- Posts: 774
- Joined: Wed May 17, 2017 8:50 am
- Location: Germany
MEMVARs, PUBLICs etc.
Guys,
in the attachment is the next step: SAVE and RESTORE of memvars
regards
Karl-Heinz
in the attachment is the next step: SAVE and RESTORE of memvars
regards
Karl-Heinz
Code: Select all
#INCLUDE "memvar.xh"
PUBLIC gc1, gc2 , gc3
PUBLIC gc4
PUBLIC ga1
PUBLIC ga2
FUNCTION Start( ) AS VOID
PUBLIC gc5 // another public
? "--------------------------"
? "PUBLICs content at startup"
? "--------------------------"
? "gc1 content:" , gc1 // ok, all show .f.
? "gc2 content:" , gc2
? "gc3 content:" , gc3
? "gc4 content:" , gc4
? "gc5 content:" , gc5
? "ga1 content:" , ga1
? "ga2 content:" , ga2
?
? "Number of PUBLICs at Start() :" , memvar:PublicsCount() // 7 , ok
?
IF File ( "publics.mem" )
RESTORE FROM publics.mem ADDITIVE
? "------------------------------"
? "PUBLICs content after RESTORE"
? "------------------------------"
? "gc1 content:" , gc1
? "gc2 content:" , gc2
? "gc3 content:" , gc3
? "gc4 content:" , gc4
? "gc5 content:" , gc5
? "ga1 content:" , ga1
? "ga2 content:" , ga2
?
? "Number of PUBLICs after RESTORE :" , memvar:PublicsCount() // 7 , ok
? "---------------------------------"
ELSE
?
? "File publics.mem not found"
?
ENDIF
// assign new values
gc1 := "gc1 " + Time()
gc2 := "gc2 " + Time()
gc3 := "gc3 " + Time()
gc4 := "gc4 " + Time()
gc5 := "gc5 " + Time()
SAVE TO publics.mem ALL LIKE gc* // save the gc1 -> gc5 content only.
?
RETURN
- Attachments
-
[The extension viaef has been deactivated and can no longer be displayed.]