10 Replies Latest reply: Nov 4, 2011 7:00 AM by Miguel Angel Baeyens de Arce RSS

    Variables

    wilnardtan

      I have this QVW running in the server and i made an input box and also made a new variable for this input box which is called Variable1.

      When i enter a value, i can see that the value i entered is there but when i close my browser and open the file in the server again the value i entered a while ago was gone..it seems to be not saving the words i input in the variable..how can i make it save the words i input into the variable so that when i close and open the server again the values are still there?

      all help, suggestions and opinions are much appreciated.

      Thanks!

        • Variables
          Miguel Angel Baeyens de Arce

          Hello Wilnard,

          Try first to create a new dummy variable using ctrl + alt + v keys and set any dummy value. Save the document, open it again and check whether the value is still stored.

          But waht ti seems to me is that you are opening the document in server, you are likely not saving the document when closing. That means that all changes you have done to the document (selections, variables) will not stored into the document, unless you save it.

          Is that correct?

            • Variables
              wilnardtan

              Hi Miguel,

              I tried the variable in my desktop and it works fine like what u suggested but my problem is that i want it to be done on the server side..

              is it impossible to save a value to a variable in the server because it does not save the document? is that what your saying?

              so there is no way into storing a value in a variable while accessing it in the server?

                • Variables
                  Miguel Angel Baeyens de Arce

                  Hello Wilnard,

                  That's the behavior when opening documents on server, you can use the objects but not (among others) save it.

                  If you want to store that variable you will have to create some macro on change or on select for the variable, under Settings, Document Properties, Triggers, Variable Event Triggers. Even so, I don't know whether that will work.

                  Regards.

                  • Variables
                    s j

                    Dear Wilnard,

                    I am agree with you that there is no way into storing a value in a variable whlie accessing it in the server.

                    reason is that there is no session management technique like cookies , reqwiting URl,session id wihch is avalilable in other web server is not available in qlikview server.

                    I think qliktech have to add session management feature in Qlikview Server.

                    Regards

                    Sunil Jain.

                      • Variables
                        wilnardtan

                        Hi Miguel

                        The only way i see this pushing through is that on a variable input i will have to save the whole file in the server to store the value..am i correct? because if this is the case then its a no go for me to do it, to avaoid having so much change going on with my file while in the server.

                        Hi Sunil Jain,

                        Thanks for you insights..i hope qliktech do something about this as it would be great to be able to store values in a variable via the server without the need of saving the document file itself.

                  • Variables
                    Colin Hancox

                    Wilnard, I don't know if this will be helpful to you, but variable values can be saved when a bookmark is created. On the Constraints sheet of the Input Box Properties there is a checkbox to Include in Bookmarks. If this is checked then every time a bookmark is created, the variable value is saved. When the bookmark is applied, the variable is reset to that value.

                    As far as achieving what you want, you could use a Variable Event Trigger to replace the bookmark every time the variable value is changed, and an On Open trigger to apply the bookmark when the document is opened.

                    I haven't tested that, but it should work.

                     

                      • Variables
                        wilnardtan

                        Hi Colin,

                        This looks like a good workaround..will try this and get back to you..

                        Thanks for the helpful inputs :)

                        • Variables
                          Miguel Angel Baeyens de Arce

                          Hello Colin,

                          Haven't thought about Bookmarks, it's worth trying.

                          Just a quick note: when opening in server, On Open, On Reload and On PostReload triggers will not execute, although you have set permissions for that.

                          Regards.

                            • Re: Variables

                              Hi Miguel,

                               

                              How to set permissions for On-Open, On-PostReload, On-PostReduce when working in server.

                               

                              Thanks in advance

                               

                              Regards
                              Venakt

                                • Variables
                                  Miguel Angel Baeyens de Arce

                                  Hi Venkat,

                                   

                                  You cannot set individual permissions for each type of triggers that QlikView has. Some of them are limited or disabled in a server - client environment, and they are documented in the Reference Manual, Book II, section 29.

                                   

                                  What you can do is to allow (or prevent) QlikView to trigger macros on document when they are used by a client. To do so, go to the QlikView Enterprise Management Console, System, Setup, QlikView Servers, expand and click the server, and on the right pane, Security, Allow Macro Execution on Server and Allow Unsafe Macro on Server. QlikView considers a macro unsafe when it has to access the filesystem (to create a file, or to send an email, for example).

                                   

                                  Hope that helps.

                                   

                                  Miguel Angel Baeyens

                                  BI Consultant

                                  Comex Grupo Ibérica