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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
sarathi_pm
Contributor II
Contributor II

how to capture msgbox value with ok cancel option

Hi,

I am writing  VB code in Qlikview and want to give the user the option to proceed or cancel .

I want to write something like this

If Msgbox ("Do you want to continue?", VbOkCancel) = VbOk then

...

else

..

End if

But this is not working in Qlikview. Does anyone know how to capture the messagebox output?

Thanks

Sarathi

5 Replies
alexandros17
Partner - Champion III
Partner - Champion III

Use alerts in Tools menu ...

sarathi_pm
Contributor II
Contributor II
Author

Hi . I want to execute the code based on a button click. When the user clicks on a button, a message box has to pop up "Do you want to continue?" OK, Cancel.

Based on what the user selects(OK or cancel), i have to do further logic.

alexandros17
Partner - Champion III
Partner - Champion III

...but to continue what???

Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

iAnswer =   Msgbox("Do you want to continue?", vbOkCancel, "Continue?")

If iAnswer = vbOk Then

  Msgbox "You answered yes."

Else

  Msgbox "You answered no."

End If


talk is cheap, supply exceeds demand
sarathi_pm
Contributor II
Contributor II
Author

I have a qlikview document which has some charts. I have written Vb code to generate a powerpoint based on a button click.

AS of now, as soon as the user clicks the button, the power point is getting generated.

I want to give the user an option when the user clicks on the button " Do you want to create a PPT?" if the user clicks OK in the msgbox then the powerpoint will be generated, If user clicks NO, then the code will simply exit.