Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Locked field and field trigger

Hi,

here is my problem:

I have a field that is locked with the trigger OnLeaveSheet. In the same time, I want that as soon as I make a selection in the field, the next sheet is automatically opened. I do this with the Field Event Trigger, OnSelect and my field. But the Trigger OnSelect totally delete the effect of the first trigger, that's to say that my field is not locked anymore.

If you have any option. Thanks in advance.

1 Solution

Accepted Solutions
Not applicable
Author

so you mean when you make a selection further down your hierarchy you want your country field to lock also?

i've attached a fix for the clearing problem also

thanks

Joe

View solution in original post

12 Replies
Not applicable
Author

Hi,

Are you able to put up an example to work with, would make it easier to see what's going wrong

thanks

Joe

Not applicable
Author

Here is an example, build with the tutorial sheets.

You can see that once selected, the country field should be locked and no change are supposed to be possible on sheet 2. But if you click on the pie chart, the selection is changed, so the field country is not locked anymore.

Not applicable
Author

you just need to add 'lock field' to your event actions on the country field,

have a look at attached, is that what you mean?

thanks

Joe

Not applicable
Author

Thanks, it already helps.

But now if I unselect a country in the first sheet, I don't want to activate the second sheet. In fact, I would like the Country field selection to be possible only on the first sheet. And the second sheet sould be activated only if one country is selected.

Not applicable
Author

Well, and actually in my real document, I'm using a hierarchy, so once I selected something in the descendant field, the field country is unlocked, especially if what I selected in the descendance is available in 2 different countries.

So I already tried it but in my case, the trigger Lock OnSelect is not really working.

Not applicable
Author

so you mean when you make a selection further down your hierarchy you want your country field to lock also?

i've attached a fix for the clearing problem also

thanks

Joe

Not applicable
Author

Ok up to this it is perfect.

If I go further down in my hierarchy, I want the country field to remain locked, since it was locked on sheet1.

Not applicable
Author

Thanks, the macro is simple but very useful.

Not applicable
Author

Hi Joe,

just a little question. When I use your macro, adapted to my doc, the sheet activation wouldn't work.  I created the variable, put the right field name and sheetID, everything works but the activateSheet.

Do you have any idea?