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

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Can i perform two actions in the same button?

Hi all,

Can any one help me in this

Here i am attaching my sample file.

I have a listbox with data.

i have a button.Now i want to perform the selection and deselection(clear) by using the same button with some seconds of time gap.

Can i achieve like this?

Thanks for any help...

9 Replies
SunilChauhan
Champion II
Champion II

if add first selection and then clear you will get no change after click on button but actions are running

see the attached file this give two action on same buttion

hope this will help

Sunil Chauhan
its_anandrjs
Champion III
Champion III

Hi,

See the attached sample by using two button you can achieve this at a time one in enabled.

Hope this helps you.

Let me know if it is not working

Regards

Anand

its_anandrjs
Champion III
Champion III

Hi,

See the updated Solution sheet.

Regards

Anand

Not applicable
Author

Hi Sunil and Anand,

Thanks for your replies.

you are taking two buttons but what happened is i must press the button two times for the complete functionality.

But,i need to achieve this by single click.

Can't  it possible in one click?

Thanks ..

SunilChauhan
Champion II
Champion II

see the 2nd attached file properly in my post

it is for single click only

Sunil Chauhan
Not applicable
Author

Hi Sunil,

Both the files what you sent are same.

Can you please check once again.

I want like this

With only one button and one click, I need to achieve the functionality.

Thanks...

its_anandrjs
Champion III
Champion III

Hi Ravi,

As my understanding it will done by on click of the button at a time and different action handeled by buttons so here we acheve this by two buttons, if i got any other way so i let you know abt that.

Regards

Anand

Not applicable
Author

HI Ravi,

What about the macro? You can easily create a macro to achieve your goal, and linked it with the button using the "Run Macro" option.

Kind regards,

Janusz

Not applicable
Author

Hi,

I am not sure if you are still looking for a solution but I came across this post, I did something similar recently.. There are different ways but you can have a look on this one:

1. You create a variable for example: vButtonAction and assign value 0 (or 1 or whatever you want actually what will separate selection later... Digits are the best way.).

2. Under the Button action the first action will be to set variable:

Variable: vButtonAction

Value: =if(vButtonAction=0,1,0)

3. You add second action for the same button: "Select in field"

Field: =if(vButtonAction=0,'F',null())

Search String: *

4, You add 3rd action for the same button: "Clear field"

Field: =if(vButtonAction=1,'F',null())

Regards,

Lukasz