Qlik Community

QlikView Publisher

Discussion Board for collaboration on QlikView Publisher.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

jasonseril
Not applicable

pass parameter (sheet) in url

Good day to all,

Is it possible to pass parameter (the name of sheet) in url, so that when qvw document is opened in AP, the specified sheet will be opened. thanks in advanc e.

jason

17 Replies
disqr_rm
Not applicable

pass parameter (sheet) in url

Yes very well possible. You would create a variable in your document and fill this variable passing parameters in the url for this variable. Then "On Open" macro you would read this variable contents and activate the sheet you want. Make sure to wipe the contents out in the same macro, and put a check in the begining to make sure variable is not initial.

Hope this will help.

jasonseril
Not applicable

pass parameter (sheet) in url

Thank you very much Rakesh. Do you have a sample application for this?

jason

deepakk
Not applicable

pass parameter (sheet) in url

it doesnt workin in Qlikview 9 using Access point.

Please share you view on this.

Not applicable

pass parameter (sheet) in url

1. Create a variable in your Document and set the value to 0.
2. Create this procedute:

Sub WhenOpen

set v = ActiveDocument.GetVariable("vSheet")
ActiveDocument.Sheets(v.GetContent.String).Activate

End Sub


3. Create a Trigger OnOpen on Document Event Triggers to run the procedure.
4. The url is qvp://localhost/MyApp.qvw?vSheet=0, where vSheet is an array. So your first sheet is 0, the second is 1...

seebach
Not applicable

pass parameter (sheet) in url

Hi,

There is a difference between doing this in Ajax and IE/Desktop. For the Windows Desktop & Plugin versions you can use the qvp:// protocal to pass a parameter. This would look like: qvp://servername/document.qvw?var=1&var=2

If you use Ajax, the only way I've been able to this is via bookmarks. If you select Remember Layout state in a new bookmark, then it will show the sheet you were on when it was created. And you can the reference the bookmark in the url by appending: &bookmark=Document\BM01

You will need to do a bookmark for each sheet you want to reference.

The bookmark method will also work in IE.

Support for setting variables via http urls would be really nice...

Regards Seebach

amien
Not applicable

pass parameter (sheet) in url

Thanks Torben!

kasdalinassim
Not applicable

Re: pass parameter (sheet) in url

@Torben Seebach

your tip works only if you creat a shared bookmark using the access point, but if you will creat a bookmark in the document using a desktop client it doesnt work.

arieidel
Not applicable

Re: pass parameter (sheet) in url

You can access directly to a specific sheet of your QVW by using de parameter "sheet" in the URL, like this:

http://servername/QvAJAXZfc/opendoc.htm?document=MyApp.qvw&sheet=MY_SHEET

Where MY_SHEET is the ID of the Sheet you want be open.

Regards,

Ariel

salto
Not applicable

Re: pass parameter (sheet) in url

As far as I know, Rakesh's solution is correct. I am using it in some of my reports, with the desired results (a trigger in the "On Open" event that activates the sheet).

Regards.