Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Macros Guide

Hi,

Do anyone have a good macros guide for beginer ?

Please share.

Thanks

1 Solution

Accepted Solutions
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

   There is no such guide like beginner.

    If you open the API guide, Go to Automation Example.

    Here you will find the example, how to use the functions related to the object.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!

View solution in original post

10 Replies
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

     You can find the API guide in "C:\Program Files\Qlikview\Documentation

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
Not applicable
Author

Hi,

That document is very detailed. As a beginner I need basic info on how to create VBScripts in the document to achieve certain tasks like exporting of documents and similar kind of ?

I m very new on this.

Thanks.

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

   There is no such guide like beginner.

    If you open the API guide, Go to Automation Example.

    Here you will find the example, how to use the functions related to the object.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
rahulgupta
Partner - Creator III
Partner - Creator III

Hey hi,

i agree with Mr Kaushik..

APIGuide.qvw is the best way to start with macros....

Just search in the Class and Member List boxes given in the Tab named: Automation Examples....

and you will get the code which you can use.....

For your support i am attaching the the APIGuide if you dont have.....!!

erichshiino
Partner - Master
Partner - Master

Hi,

I agree the documents do not make it very very simple to start.

The attached document came with the installation of QV9 but the content is basically the same that works for QV 10.

The first chapters can help you start.

Hope it helps,

Erich

Not applicable
Author

Thanks Erich

Not applicable
Author

Hi all,

I understood what you all are saying. Actually I m having certain doubts with some keywords,

Lets say this.

CreateObject("Scripting.FileSystemObject")

In automation Example, neither Scripting, FileSystemObject nor CreateObject is there.. So what are they ?

Also this one..

CreateObject("Excel.Application")

Please guide.

Thanks.

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

     There are 2 languages in which the modules can be written. JavaScript and VBScript.

     So when you want to write module using the API, you must know the language in which you are writting the module. I mean the JavaScript or VBScript.

     The CreateObject() function is not available in API guide. cause its a VBScript Function.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
rahulgupta
Partner - Creator III
Partner - Creator III

Hey hi,

For the beginning purpose you can use the following code:

For the Selection of the Max Year on the call of the macro:

sub CurrentBudgetYrSelect

          set f=ActiveDocument.GetField("[FISCAL_YEAR]")

          set v1 = ActiveDocument.Variables("vMaxYear")

          'msgbox v1.GetContent.String

          'f.select year(now)

          f.select v1.GetContent.String

end sub

For the purpose of the Calling the Outlook via functions:

Sub OutlookOpen

         set app= ActiveDocument.GetApplication

         app.Launch "C:\Program Files\Microsoft Office\Office12\OUTLOOK.EXE",""

end sub