Archive: Disable the Cancel Function of CANCEL button


Disable the Cancel Function of CANCEL button
Hi,

i need to use the default CANCEL button for other functions like generating log,refresh etc..instead of creating a new button.I am able to rename the cancel button,but still functions the same as CANCEL button.

For example: I need to use the CANCEL button for generating log of my application,how to write code on the Click function of the CANCEL Button.

Please refer the attached screenshot.

thanks in advance


You can do what you need in .onUserAbort and then call Abort to cancel the cancel operation.


thanks much!!!

-VINS


Like that how to cancel the close operation of CLOSE button on the right side of the window?

-VINS


Yes, it's the same function.


I am a newbie..please guide....

When I use below function, CANCEL button is operating(tats in the left side in pic) and moreover the X-close in top right also intiating the same function as CANCEL.tats y planned to write this code in the click of CLOSE button(in the right side)

Function .onUserAbort
MessageBox MB_YESNO "Do you want to view more information?" IDYES ViewLog
Abort
ViewLog:
nsExec::Exec "$PLUGINSDIR\sys.bat"

ExecShell "" "log.txt"
Abort
FunctionEnd




-VINS


The X button is linked to the Cancel button, so you can't have it not do that. Maybe you can use the HelpButton plug-in for what you're looking.


thank u Kitchik....let me try...

-VINS