UniStudent Posted July 3, 2007 Share Posted July 3, 2007 right iv made a button that when pressed displays a msgbox the box displays a yes and no button, can any one tell me how i sense the return value of the yes button i believe its 6. i besicaly whant to sense if the yes button has been pressed then run a function If $msg = $button30 Then Msgbox(68,"PUP- WARNING","blarblar blar"& @CRLF & "Do You Want To Proced?") if Return (6) Then washdrive()something like that but were the if return function actually dose something Link to comment Share on other sites More sharing options...
herewasplato Posted July 3, 2007 Share Posted July 3, 2007 tryIf $msg = $button30 Then $ret = MsgBox(68, "...", "...") EndIf If $ret = 6 Then washdrive ()MsgBox shortened for posting. [size="1"][font="Arial"].[u].[/u][/font][/size] Link to comment Share on other sites More sharing options...
UniStudent Posted July 4, 2007 Author Share Posted July 4, 2007 thats the one but it seems that it wants the final if inside the endif but any how it seems to do the job tar Link to comment Share on other sites More sharing options...
herewasplato Posted July 4, 2007 Share Posted July 4, 2007 thats the one but it seems that it wants the final if inside the endif but any how it seems to do the job tarIf $msg = $button30 Then $ret = MsgBox(68, "...", "...") If $ret = 6 Then washdrive () If $ret = 7 Then ExitYou really don't need any EndIf for those simple lines. I just used one to prevent the MsgBox from wrapping in the post. [size="1"][font="Arial"].[u].[/u][/font][/size] Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now