10 Replies Latest reply: May 25, 2011 1:33 AM by sachinaddy RSS

    Macros Guide

      Hi,

       

      Do anyone have a good macros guide for beginer ?

       

      Please share.

       

      Thanks

        • Macros Guide
          Kaushik Solanki

          Hi,

           

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

           

          Regards,

          Kaushik Solanki

            • Macros Guide

              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.

                • Macros Guide
                  Kaushik Solanki

                  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

                  • Re: Macros Guide
                    Rahul Gupta

                    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.....!!

                    • Re: Macros Guide
                      Erich Shiino

                      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

                        • Re: Macros Guide

                          Thanks Erich

                            • Re: Macros Guide
                              Rahul Gupta

                              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

                      • Macros Guide

                        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.

                          • Macros Guide
                            Kaushik Solanki

                            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

                          • Macros Guide

                            Hi all,

                             

                            Thanks all for the replies.

                             

                            I will go through those.

                             

                            Regards,

                            Sachin A.