Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, I'm going mad trying to do this:
ActiveDocument.GetVariable("myvar").SetContent "aaaa", true
I put this in a Macro, I want to do this when I click on a button.
If I use it in desktop version, it works correctly, but if I use the in Ajax Plugin (QV Server 11) version it doesn't work.
Can someone help me?
Thanks!
Aki76
Hi,
Use an action instead. For example, create a new button, got to its properties, Actions, External, Set Variable. So when you click on it, tha variable should get the vale specified.
Hope that helps.
Miguel
Thanks Miguel,
but I have to use this action in a more complex script, I can't use a button directly but the assignation has to be set into a macro. It's the reload script, that doesn't assign the variable correctly and so I can't have a feedback of the end of the reload....
Aki76
Hi,
I may have understood you wrong: certain macros cannot be used in the script (neither in Desktop nor in Server), because ActiveDocument is only valid when the document is actually active, meaning that after the reload, when the reload dialog has gone and you can interact with the data.
Could you please elaborate on your actual requirements?
Miguel
but then how can I have an assignment?
I need have a feedback of the success of the reload... and the EDX Reload Script I have use this way to alert me that I finished reloading.
ActiveDocument.GetVariable("vAjaxMsg").SetContent sMsgTxt, true
then I have a textbox where I want to see sMgsTxt (Reload succesfull, failed,...)
i the line doesn't works. I need to refresh an object first? How?
There are no other method to do this?
Aki76
Ok,
So you want to control when a task has been completed successfully without need to see the QMC.
One way to achieve this is to store that value into a QVD file instead if the script reached the last line all right, then have another task that reloads depending on the first (you can set task dependencies in the QMC) and shows that textbox.
Hope that helps.
Miguel
mh good idea...
I'll try and I'll report you.
Thanks
Aki76