Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Macro code is not executing in qvs

Hello,

I've below macro code in my qvw file.

sub resetinput

dim x(1)

x(0) = 0 ' element to reset

set fld = ActiveDocument.Fields("MaxTakeOver")

fld.ResetInputFieldValues 0, x ' 0 = All values reset, 1 = Reset Possible value, 2 = Reset single value

set fld = ActiveDocument.Fields("MinTakeOver")

fld.ResetInputFieldValues 0, x ' 0 = All values reset, 1 = Reset Possible value, 2 = Reset single value

end sub

i'm executing this code with action on OnPostReload Trigger.

It is working perfectly when i reload the application manually. But when i schedule this qvw file in publisher for every 5mins. This macro code is not executing and i'm not able to reset those fields.

Can anyone help me on this.

3 Replies
bnichol
Specialist
Specialist

The QlikView server does not execute macros on scheduled reloads. 

Here's a link with a possible solution... http://community.qlik.com/thread/35982

Good luck,

B

erichshiino
Partner - Master
Partner - Master

Hi,

bnichol is right...

You can try to use it on the onOpen event or onActivate of a sheet.

I tried this before and in my case, sometimes the action was not properly triggered

Good luck,

Erich

Not applicable
Author

Thanks for your help..