Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Leverage your QlikView investment to modernize BI – see how! Join Group
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Not applicable

Basic Question on Bookmark

Hello,

I have a very basic requirement of dislaying bookmark name in a text box (if there is an active book mark selection).

Is there any out of box variable/function can be used to display this? or is there any way to achive this?

Thanks,

Aji Paul.

1 Solution

Accepted Solutions
Highlighted
MVP
MVP

Re: Basic Question on Bookmark

Aji

If you use my approach, then the report title could be dynamic, like this:

=GetFieldSelections(BMName)

(assuming only one bookmark name selected)

Regards

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein

View solution in original post

12 Replies
Highlighted
Not applicable

Basic Question on Bookmark

Hi this is a macro to pick tha name (copied from ApiGuide.qvw):

set bm = ActiveDocument.GetBookmark("BM01")

if bm.Default = true then

    msgbox(bm.Bookmark.Name)

else

    msgbox("Bookmark does not exist")

end if

But You have to get a target bookmark...

Try to search in ApiGuide.qvw if there is a way to discover the bookmark selected...

C u,

Stefano.

Highlighted
Not applicable

Basic Question on Bookmark

Stefano,

Thanks for the direction.

I never used any API with QV(just getting hands around QV).

BTW where do I try this code. As textbox properties?

Highlighted

Basic Question on Bookmark

Hi,

There is a Module editor in QlikView in addition to the Script editor that you already know. Go to Control + M to use the QlikView API and VBScript or JScript code according to the APIGuide.qvw file syntax. This file is located in the Documentation folder if you do the complete instalation.

Hope that helps.

Miguel Angel Baeyens

BI Consultant

Comex Grupo Ibérica

Highlighted
Not applicable

Re: Basic Question on Bookmark

Thanks Miguel!

Pardon my unawareness! What are some practical application of  APIs?

Can APIs be used in the following scenario? When a book mark is selected,navigate to a specific sheet.

(I am still waiting for the approval of QV training from my employer)

Highlighted

Basic Question on Bookmark

Hi Aji,

No problem, this is what the QlikCommunity is for.

In regards to your particular question, there is no need for a macro. When you create a bookmark, make sure you click "Include Layout State" and you will get to the same point of selections, scroll in charts and same sheet where you created it. So first of all, go to the sheet you want to be moved, and there create the bookmark.

Hope that helps.

Miguel Angel Baeyens

BI Consultant

Comex Grupo Ibérica

Highlighted
Not applicable

Re: Basic Question on Bookmark

Thank You Miguel! That helps a lot!

BTW what are the typical uses of these APIs?

Highlighted
MVP
MVP

Re: Basic Question on Bookmark

Aji

I have a fully documented process for displaying the active bookmark from a set of bookmark at my blog. This is how it displays (its a list box). This process does not require macro code, only a little setup and a couple of actions.

visual BM.png


Have a look at the blog article here.

I would be happy to answer any questions you may have if you get stuck.

Regards

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Highlighted
Not applicable

Re: Basic Question on Bookmark

Thanks Jonathan! Very interesting!

My plan was creating few bookmarks on a sheet, then excutive can select the bookmark and it will update a text box with the bookmark name. So it will serve as a report title

Highlighted
MVP
MVP

Re: Basic Question on Bookmark

Aji

If you use my approach, then the report title could be dynamic, like this:

=GetFieldSelections(BMName)

(assuming only one bookmark name selected)

Regards

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein

View solution in original post