Closed macMikey closed 2 years ago
do you have use com.livecode.engine
in the code?
yes. I'm working on NavRAD, so it looks like it's got all the USE lines in it.
use com.livecode.canvas
use com.livecode.widget
use com.livecode.engine
use com.livecode.library.iconsvg
use com.livecode.library.widgetutils
Ok, the error is from the IDE and not the compiler. I'm getting the same thing.
This issue is where/when you are attempting to use script access. Where in the flow of the widget creation are you calling that handler?
Note: An error is thrown if this syntax is used in a context where access to script objects is not allowed.
Not sure what that exactly means though.
In OnLoad()
to debug the value of a property, since I don't think we have a real debugger in lcb
So I took that one out, and I have one in CalculateIconRects()
, which is called in OnCreate()
, but that's also throwing the error, so I'm guessing it's still too early.
Yes, I would infer that until the widget is fully created that you can’t use the script. The message is going to the script object.
this does not work:
I get Script access not allowed