[JW Lua] ExecuteLuaScriptItem: returning an error message - still not working

Jan Angermüller jan at angermueller.com
Thu Dec 22 17:46:06 CET 2022


Hm, I still didn't succeed.

When I throw an error message in a lua script with:
/error("Cancel",2)/
then this a user dialog always pops up in RGP Lua/Windows:


Is there a way to not show this dialog in RGP Lua?
(Tested in Fin27.2/Windows 10/RGP Lua 0.65)

This happens without/finenv.ExecuteLuaScriptItem/ , it's just the 
/error(...) /that leads to the popup./
/
The same code in JW Lua doesn't give a dialog that pops up.

Or does anyone have an example code of how to end a lua script so that 
it passes a "not successful" to /finenv.ExecuteLuaScriptItem /without 
showing any error messages.

Jan



Am 20.12.2022 um 01:27 schrieb Robert Patterson:
> As far as I can tell, ExecuteLuaScriptItem is working as documented 
> <https://www.finalelua.com/docs/rgp-lua/finenv-properties#executeluascriptitem-function>. 
> It is not the same behavior as a command line tool. As for the 'error' 
> function, it will close the Lua state of the called script, but that 
> would appear to be what you want anyway. Otherwise you can return a 
> string that will be returned in the second return value of 
> ExecuteLuaScriptItem.
>
> _______________________________________________
> JWLua mailing list
> JWLua at jwmusic.nu
> http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu

-- 
Jan Angermüller
Orchideenstieg 13
22297 Hamburg
Tel. 040 - 28 94 84 82
Mobil 0173 - 99 33 904
www.elbsound.studio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://jwmusic.nu/pipermail/jwlua_jwmusic.nu/attachments/20221222/c21352cf/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mNLYw0I5JU0LmXji.png
Type: image/png
Size: 3362 bytes
Desc: not available
URL: <http://jwmusic.nu/pipermail/jwlua_jwmusic.nu/attachments/20221222/c21352cf/attachment.png>


More information about the JWLua mailing list