22 Replies Latest reply: Dec 4, 2012 11:43 AM by Daniel Steinhoff RSS

Button to record user Usage

Anne Duffy

Hi Experts

 

I have a QV dashboard with 10 different users, I need to know who is actually using the dashboard and when ( Its an internal debate issue !!)

 

Our support have told me that there is no easy way to record this so I was thinking that ( AND I DONT KNOW IF THIS IS POSSBLE)

as a work around --

Hide all sheets - bar one

On this sheet put a button that when toggled

shows all sheets and

*Presumably uses a macro to update an Excel file on the s drive with data based on users info

 

-- Hence I would have a log of all users!!!

 

 

Has anyone got any feedback on this ?


Do you think its possible?

 

Should I not even try and persue it ?

 

Any advice greatly appreciated

 

Thanks


A

  • Button to record user Usage
    m woolf

    Yes, this is possible.

    Use osuser() to get the userID

    You will find many posts telling you how to write to an Excel file.

    • Button to record user Usage
      Anne Duffy

      Thanks mwoolf!!!

       

      Ill start research mode so

      • Button to record user Usage
        m woolf

        A problem that you may encounter is that users will have to accept System Level macros when they open the application.

         

        There are some posts that describe how to force this through registry entries.

         

        If you can be sure that users have accepted system level macros, you don't need to use a button or hide any sheets.

        You can set a macro to run when the document is opened.

        • Button to record user Usage
          Anne Duffy

          Hey Mwoolf

           

          I have never successfully used macros in QV , today this will change !!

           

          I have seen that message and to be fair to our users they tend to always check for allowance,


          its easy enough for me to communicate with them to allow them anyway !!

           

          Do you have any sample of a QV macro that runs on open , or any macro that I can look at ?

          • Re: Button to record user Usage
            m woolf

            Take a look at the attached qvw.

            • Re: Button to record user Usage
              Anne Duffy

              Mwollf

               

              Honestly,

               

              This is great thanks so much that would have taken me ages, if you're ever in dublin Ill get you a pint

               

              Thanks

            • Button to record user Usage
              Anne Duffy

              QV Error.bmp

              Hey Guys

               

              It seems to be working fine for developers on the Server but those using a viewers license are getting the following message

              -- Any suggestions ?

               

              Thanks

              A

              • Button to record user Usage
                m woolf

                They either don't have Excel or they haven't set System Level Access.

                • Button to record user Usage
                  Anne Duffy

                  Hi there,

                   

                  The Excel file is saved onto the server and it works fine for the 2 developers its only the viewers that are having this issue -- in saying that Excel is not installed on the server, nor will it be !! Does this mean this is a non runner now ?

                   

                  When I Ctl + Shift+M I see that the Macro level seems to be fine !!!

                   

                  How do they set System Level Access ?

                  As always any suggestions greatly appreciated !

                   

                  Thanks
                  A

                   

                  excel error.bmp

                  • Button to record user Usage
                    m woolf

                    Excel doesn't need to be installed on the server.

                     

                    Have the end user do Shift+Ctrl+M to check the macro access level.

                    • Button to record user Usage
                      Anne Duffy

                      Hi Mwoolf

                       

                      for the viewers it is set to "Limit Module....." but even if they click onto "Give System ....." it does not run, presumably they need to change to that and save it and then everytime they open thereafter it would work !!

                      But I dont know how to allow the viewer to Save this change ,


                      Do you ?

                      • Button to record user Usage
                        m woolf

                        Registry entry should be saved when user selects. Are these users administrators of thier computers?

                         

                        If not, you may need to set the appropriate registry key for them.

                        • Button to record user Usage
                          Anne Duffy

                          Hi Im having issues replying , I hope you get this

                           

                          Nobody in this office are administrators of our PCs , do you know how an administrator would change /amend the registry key ?

                           

                          Thanks

                          • Button to record user Usage
                            m woolf

                            The administrator will log into the PC and run the following vbscript. Copy the script and paste into a text editor. Then save with any name and a .vbs extension.

                             

                            '// ************************************************** 

                            '// Script for adding some registry keys to the current user profile/registry settings 
                            '// for enabling the macro security/module security for the SERVER defined below 
                            '// ~ 

                            '// CONFIGURATION 

                            '// Just configure the script by defining your server below 

                            '// ~ 

                            '// The article explaining this script can be found at 

                            '// http://www.qlikblog.at/523/ 

                            '// ************************************************** 

                            CONST cSERVER_NAME = "YOUR_SERVER_NAME"

                            Dim WshShell 'as Object 

                            ' Delete any registry entries where the user blocked script for the server
                            on error resume next
                            WSHShell.RegDelete "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\Module Script Blocked\" & cSERVER_NAME
                            WSHShell.RegDelete "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\Module Script Blocked\"
                              

                            Set WshShell = WScript.CreateObject("WScript.Shell") 

                            WshShell.RegWrite "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\", 1, "REG_SZ" 

                            WshShell.RegWrite "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\Module Script System\", 1, "REG_SZ" 

                            WshShell.RegWrite "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\Module Script System\ " & cSERVER_NAME, "", "REG_SZ"

                          • Button to record user Usage
                            m woolf

                            I have tried to reply 3 times with no success.

                            • Button to record user Usage
                              Anne Duffy

                              Hi Mwoolf

                               

                              Ive had same issue !!!

                              • Button to record user Usage
                                m woolf

                                I posted a reply regarding how an admin would change the registry settings and got a message saying that my post had to be approved by a moderator.

                                We'll see if it shows up later today.

                                • Button to record user Usage
                                  Anne Duffy

                                  Thanks Mwoolf

                                   

                                  Hopefully they approve it and I get to read it

                                  • Button to record user Usage
                                    m woolf

                                    I'm trying again.

                                     

                                    The admin will log into the PC and run this vbscript.

                                    Copy the script and paste into a text editor.

                                    Change cSERVER_NAME to your server name.

                                    Save with any name and a .vbs extension.

                                     

                                    '// ************************************************** 

                                    '// Script for adding some registry keys to the current user profile/registry settings 
                                    '// for enabling the macro security/module security for the SERVER defined below 
                                    '// ~ 

                                    '// CONFIGURATION 

                                    '// Just configure the script by defining your server below 

                                    '// ~ 

                                    '// The article explaining this script can be found at 

                                    '// qlikblog.at/523   ' put www. in front

                                    '// ************************************************** 

                                    CONST cSERVER_NAME = "YOUR_SERVER_NAME"

                                    Dim WshShell 'as Object 

                                    ' Delete any registry entries where the user blocked script for the server
                                    on error resume next
                                    WSHShell.RegDelete "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\Module Script Blocked\" & cSERVER_NAME
                                    WSHShell.RegDelete "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\Module Script Blocked\"
                                      

                                    Set WshShell = WScript.CreateObject("WScript.Shell") 

                                    WshShell.RegWrite "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\", 1, "REG_SZ" 

                                    WshShell.RegWrite "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\Module Script System\", 1, "REG_SZ" 

                                    WshShell.RegWrite "HKCU\Software\QlikTech\QlikOcx\Settings for Qlikview Servers\Module Script System\ " & cSERVER_NAME, "", "REG_SZ"

                                  • Button to record user Usage
                                    m woolf

                                    I tried again without success.

                                     

                                    See if you can read this blog:

                                    www.qlikblog.athttp://www.qlikblog.at/523/

  • Re: Button to record user Usage
    flipside

    You might find the Audit logs of interest for this requirement which reside at ...

     

    C:\ProgramData\QlikTech\Qvs on the server, but you will need to switch on client activity logging in QEMC.

     

     

     

    flipside