Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am always trying to keep my QlikView_apps slim and tidy and understandable for outsiders.
One thing that has been bothering me is variables that are not needed anymore or are not even part of the code anymore, but that have been created at some time or other and are still around there.
=> Is there any way to delete variables after they have been used?
Thanks a lot!
Best regards,
DataNibbler
Goto edit script->Settings(tab - the left bottom)->Check 'Can Execute External Programs'
Hello.
Yes, you can delete variables that you won't need anymore. Just use:
Set variable = ;
There's one caveat. It only work for variables that were created for the first time in the script. If the variables are already in the Variable Overview, you'll need to delete them there first.
Regards.
Thanks Bruno!
I'll try that out immediately. Can I also clean up files (qvd) that I have created in the process?
Try like:
Execute CMD.EXE /C del "qvdname.qvd";
Hi tresesco,
that sounds promising. I was supposing you could do some cool things with that EXECUTE command, but honestly I'm not good at working in the command line.
Thanks a lot!
I'll try.
Hi tresesco,
I am getting an error that the command may not be executed because I don't have the access_rights. I wonder why - the file I want to delete is on the QlikViewServer which I have RW access to.
Do I have to specify the complete file_path? I guess I do ...
P.S.: Well, I still got the error, but this time round I clicked on OK and the command was executed anyway. Of course there's no way I can manually execute the script in the time_interval we need and click on OK at this point every time.
=> Is there any way I can pass something like the /f (force) option?
Goto edit script->Settings(tab - the left bottom)->Check 'Can Execute External Programs'
Yes, you have to specify a path to every QVD (you can use variables to make that more flexible). Otherwise, the reload engine will try to find those QVD's in the directory where the QVW model resides (User Documents), or where you were after the last Directory; script statement.
Hi tresesco,
that worked.
I got a dialog_field once, but now it seems the script runs without asking.
Thank you!
O_O - I still get that dialog_window and have to confirm that I want to run the script with access to external files ...