Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
hmjason7
New Contributor

Run a Macro every 5 seconds

Hi All,

I have a macro that I would like to run every 5 seconds. What is the best way of doing this?

The macro basically selects every possible value for a given field. So if I have a button with the macro "Test" as an action, every time I click on it, the field "Field" will select a different value each time.

But naturally I don't want to have to keep clicking on this every 5 seconds. How can I automate this process, i.e. have this macro run every 5 seconds in the background?

Sub Test

ActiveDocument.getField("Field").select ActiveDocument.Evaluate("minstring({1}if(Field>'$(=Field)',Field))")

end Sub

Cheers,

Jason

Tags (3)
3 Replies
agni_gold
Valued Contributor II

Re: Run a Macro every 5 seconds

Are you using Qlikview server ?

hmjason7
New Contributor

Re: Run a Macro every 5 seconds

No, currently I am just demoing this on the desktop.

agni_gold
Valued Contributor II

Re: Run a Macro every 5 seconds

So without server you cannot do this ,

Do one thingh , create a button and add the action on it to run the macro  (But it is a manual process user have to click on the button )

Community Browser