Quote from ema on May 26, 2020, 12:48 pmHi, i am new in this forum. I'd like to know how to assign the result of the neoGetItemsNames to a variable to inspect it. Example:
neoGetItemsNames [name_DB] "routine_delay" SetVar [first_position] [name_DB(0)]but it doesn't work.
Thanks in advance
Hi, i am new in this forum. I'd like to know how to assign the result of the neoGetItemsNames to a variable to inspect it. Example:
neoGetItemsNames [name_DB] "routine_delay" SetVar [first_position] [name_DB(0)]
but it doesn't work.
Thanks in advance

Quote from luishp on May 26, 2020, 4:33 pmHi @ema and welcome to the forum!
Please take a look at the attached sample (right click to save). The key point here is understanding these commands are asynchronous. This means the next command is executed even if the current one has not finished yet. That's the reason you should use callback subroutines, as they will allways be executed when the command has finished its work.
Regards.
PD: When pasting text from Google Translator use Shift-Ctrl-V instead of Ctrl-V so it is pasted without format.
Thank you!
Hi @ema and welcome to the forum!
Please take a look at the attached sample (right click to save). The key point here is understanding these commands are asynchronous. This means the next command is executed even if the current one has not finished yet. That's the reason you should use callback subroutines, as they will allways be executed when the command has finished its work.
Regards.
PD: When pasting text from Google Translator use Shift-Ctrl-V instead of Ctrl-V so it is pasted without format.
Thank you!
Quote from ema on May 26, 2020, 5:07 pmMany thanks Luis! Yor example is very useful. I'll try it right away. To try to solve the problem instead I had put an Wait instruction but it didn't work. Sorry for the incorrect copy from Google Translator :-(
Regards.
Many thanks Luis! Yor example is very useful. I'll try it right away. To try to solve the problem instead I had put an Wait instruction but it didn't work. Sorry for the incorrect copy from Google Translator :-(
Regards.

Quote from luishp on May 26, 2020, 6:05 pmGreat @ema, but using Wait is also possible. This works for me:
neoGetItemsNames [mylabels] "" Wait 300 SetVar [firstLabel] [mylabels(0)] AlertBox "First Label" "[mylabels(0)]" "" EndWaitRegards.
Great @ema, but using Wait is also possible. This works for me:
neoGetItemsNames [mylabels] "" Wait 300 SetVar [firstLabel] [mylabels(0)] AlertBox "First Label" "[mylabels(0)]" "" EndWait
Regards.
Quote from ema on May 27, 2020, 11:04 amMany thanks Luis! Sorry for my late answer. The problem was that I had forgotten the EndWait statement even though compiling it didn't give me errors.
The instructions about neoLocalStorage can generate different results in local storage of the browser if the program is running from VisualNEOWeb (call from browser button) or from compiled files (index.html, ecc.)?
Thanks in advance
Regards
Many thanks Luis! Sorry for my late answer. The problem was that I had forgotten the EndWait statement even though compiling it didn't give me errors.
The instructions about neoLocalStorage can generate different results in local storage of the browser if the program is running from VisualNEOWeb (call from browser button) or from compiled files (index.html, ecc.)?
Thanks in advance
Regards

Quote from luishp on May 27, 2020, 5:09 pmHi @ema
The instructions about neoLocalStorage can generate different results in local storage of the browser if the program is running from VisualNEOWeb (call from browser button) or from compiled files (index.html, ecc.)?
I don't understand your question, sorry.
neoLocalStorage plugin is based on LocalForage Javascrip Library and it uses the best option available in the current browser to store local data. It uses asynchronous storage (IndexedDB or WebSQL) or localStorage in browsers with no IndexedDB or WebSQL support. I hope it helps.Best regards.
Hi @ema
The instructions about neoLocalStorage can generate different results in local storage of the browser if the program is running from VisualNEOWeb (call from browser button) or from compiled files (index.html, ecc.)?
I don't understand your question, sorry.
neoLocalStorage plugin is based on LocalForage Javascrip Library and it uses the best option available in the current browser to store local data. It uses asynchronous storage (IndexedDB or WebSQL) or localStorage in browsers with no IndexedDB or WebSQL support. I hope it helps.
Best regards.
Quote from ema on May 27, 2020, 5:49 pmHi Luis,
I apologize if I explained myself wrong. I wanted to know if the results (data stored in browser) can be different if the program is executed from the VisualNEO Web development environment or if the program is externally executed by VisualNEO Web.
I hope I explained myself.
Thanks in advance
Regards
Hi Luis,
I apologize if I explained myself wrong. I wanted to know if the results (data stored in browser) can be different if the program is executed from the VisualNEO Web development environment or if the program is externally executed by VisualNEO Web.
I hope I explained myself.
Thanks in advance
Regards

Quote from luishp on May 27, 2020, 7:05 pm@ema the way data is stored should be the same, but the actual data stored is dependant on the context. That means the browser will consider each piece of data stored to be owned by the app URL. So, if you execute your app under different domains or protocols (file:// http:// https://) the web browser will consider each one a different app and so tha data stored from one of them will be not accesible from the other one.
Does this answer your question?
Regards
@ema the way data is stored should be the same, but the actual data stored is dependant on the context. That means the browser will consider each piece of data stored to be owned by the app URL. So, if you execute your app under different domains or protocols (file:// http:// https://) the web browser will consider each one a different app and so tha data stored from one of them will be not accesible from the other one.
Does this answer your question?
Regards