Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Back to the last sheet, how can I do it?

Hey guys, I need some help...

I need to create a way for back to the last sheet, it'll be a button with an action to back, but the user can be in any sheets, maybe with a concat it can be solved

can someone help me?

thx

Rodrigo

1 Solution

Accepted Solutions
flipside
Partner - Specialist II
Partner - Specialist II

Try this ...

flipside

View solution in original post

8 Replies
Not applicable
Author

Hi

Use below macro.

sub Back_Button()
ActiveDocument.Back
end sub

Call this macro in button using triggers.

Not applicable
Author

I'm doing a version for iPad, so... I can't use macro 😕

but thank you for reply, it'll be helpfull for me too

flipside
Partner - Specialist II
Partner - Specialist II

I'm thinking Dynamic Update might be of use to create a 'breadcrumb' table. If you are in QV11 then you need an empty table similar to this in your load script ...

Navigation:

Load * Inline [

Sheet,    Index

SH01,0

];

... then put an activate trigger on each tab to dynamically update this table ...

Action = Dynamic Update:

INSERT INTO * (Sheet, Index) VALUES (ID,=max(Index)+1)

... where ID is the ID of the sheet.  Then you can navigate back using a button with 3 actions ...

1) To delete the last entry ...  ='DELETE FROM Navigation WHERE Index = ' & max(Index)

2) Activate sheet ...               =only({<Index={$(=max(Index))}>}Sheet)

3) Delete the entry just triggered ... ='DELETE FROM Navigation WHERE Index = ' & max(Index)

It's not perfected (the first button press needs two pushes) and you can't navigate forward because you've deleted the record - perhaps a variable holding a pointer reference would be better. I also need to wraparound some logic to ensure a valid number (i.e. not null) is inserted on the INSERT trigger, but it works in essence.

flipside

Not applicable
Author

wow almost there hahaha

can you send me an example? I'm with a little difficulty

thx

flipside
Partner - Specialist II
Partner - Specialist II

Try this ...

flipside

Not applicable
Author

Thank you very much flipside, it's exactly what I've been looking for.

Not applicable
Author

flipside - I tried your example, but the back button does not actually navigate to the previous sheet.  I see the values in the table change but no navigation occurs. 

Also can the hardcoded sheet number be replaced with a function of some sort to detect the current sheet instead of hardcoding it? 

Regards,

Rich

buffalome90210
Contributor III
Contributor III

Wow, try do this in seance is crazy, the sense product is less than half baked!!