global is empty

JJS jjs at krutt.org
Sat Jan 19 15:30:27 EST 2019


Hi,


i've never had this before and i believe it is a stack fault rather than 
an actual bug.

Because with another stack the same principe is working correct. Using 
LC902.

With  the current stack the global gLocalDbID of the next line is empty 
once the new card is opened.

put revOpenDatabase("sqlite", gDatabasePath, , , , ) into gLocalDbID


The line is in the stack script, the splash card is shown and after a 
few seconds the first actual card is opened where you can select something.

The stack is for mobile, but all this happens in the IDE.

So i checked if the global is declared on each card/button is used.

Checked and outcommented any line that would close the database or empty 
the gLocalDbID.

Checked the global just before switching to the other card, then it's there.

On opening the other card, it's gone, empty, even in the preopening card 
part.

So it seems only happening that moment. Switching between other cards is 
no problem, the id in gLocalDbID is present, because i added an "if 
then..." to check the id and reopen the database if it is no number.

Strange thing is, all other globals who also come from the stack script 
are there, except not the one from revOpenDatabase.


And since it works with the other stack, i was banging my head against 
the wall, not understanding why the global was empty.


Has anyone had a similar issue with the this? The global from the 
revOpenDatabase i mean, not the bump on my forehead now :)


Thanks, Jerry







More information about the use-livecode mailing list