error using "wait ....endwait" in dialogbox - Forum

Forum Navigation
You need to log in to create posts and topics.

error using "wait ....endwait" in dialogbox

Hi @luishp, I report this strange behavior.
Using a "wait ... endwait" in a button on a dialog box I get an error in the console, this:
ReferenceError: $ timeout is not defined
a b. $ scope.PushButton2_click (main.js? v = 76: 28: 1)
at fn (eval at compile (angular.js: 16548: 15), <anonymous>: 4: 176)
in e (angular.js: 29123: 13)
a b. $ eval (angular.js: 19523: 16)
a b. $ apply (angular.js: 19622: 20)
in HTMLButtonElement. <anonymous> (angular.js: 29127: 13)
in HTMLButtonElement.dispatch (jquery.min.js: 2: 43064)
in HTMLButtonElement.v.handle (jquery.min.js: 2: 41048)

If I write the code in a subroutine with the same code and call it from the button everything works fine and I don't get any errors.

Can't I use "wait ... endwait" directly in dialog boxes?

An example in attach

Rocco

Uploaded files:
  • You need to login to have access to uploads.

Hi @roccocogliano, not sure what's happening there.
Those commands were coded by Dave. I will try to check them as soon as I can.
Meanwhile please use the workaround you have found or SetTimeOut command.
Thank you!

roccocogliano has reacted to this post.
roccocogliano

Thank you so much @luishp