Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
jrepucci15
Creator
Creator

DocumentPath() in v12.40 SR1

I'm trying to replace QvWorkPath with DocumentPath() in v12.40 SR1.  It appears that QvWorkPath was removed in this version.

Per the documentation,

DocumentPath
This function returns a string containing the full path to the current QlikView document. It can be used in both
the load script and in a chart expression.

DocumentPath() does return the full path when I refresh using the desktop.
         D:\Data\Staging-Shipping\DEV-Insight-Shipping.qvw

When the application is refreshed by QV, the path is very different.  Missing the drive & path info and case differs
        staging-shipping\dev-insight-shipping.qvw

I'm looking at the same instance of the application in both cases and have "=DocumentPath()" in a text box.

Does anyone have a solution for this?

John

 

Labels (4)
1 Solution

Accepted Solutions
jrepucci15
Creator
Creator
Author

Marcus,

Your feedback gave me the hint to fix my issue.

I added the below line to my script and  modified my show/hide expression to use the variable and it works as expected.   (I display an ugly pink text box background when the app is not running on the prod server or not running in the production folders.)

 Let vDocumentPath = DocumentPath();

Thank you.

I did go through the v12 release notes (initial's only) and did not find any reference to QvWorkPath being removed.

View solution in original post

2 Replies
marcus_sommer

If I look on the Qlik help there are various system-variables not be listed anymore in QV April 2019 - maybe the release notes give any hint to the why and if there any new features implemented which could replace these information and also if it has an impact on other functions like documentpath() which may be based on these variables.

The differences between client and server might be caused from the storage itself - if it's a share-drive or a mapped drive and/or the storage has no name else only an IP and/or there is any issue with the DNS resolution or something similar. This are just a few ideas what might goes wrong and I think it would be rather ugly to detect and to solve it in this way.

Therefore I would look to find another way, for example with storing the value within a table during the script like:

documentpath: load documentpath() as documentpath autogenerate 1;

- Marcus

jrepucci15
Creator
Creator
Author

Marcus,

Your feedback gave me the hint to fix my issue.

I added the below line to my script and  modified my show/hide expression to use the variable and it works as expected.   (I display an ugly pink text box background when the app is not running on the prod server or not running in the production folders.)

 Let vDocumentPath = DocumentPath();

Thank you.

I did go through the v12 release notes (initial's only) and did not find any reference to QvWorkPath being removed.