mIRC Homepage
Posted By: SergioNL /exit -d - 07/03/03 02:55 AM
an options -d (dont confirm)
in the /exit command

that would be usefull for muh autorecover mirc.ini script with loads another mirc.exe closes the normal mirc.exe and that other mirc.exe recovers the mirc.ini of the normal mirc.exe and restarts the normal mirc.exe again,
if ppl have that confirm on is kinda hard to do that

sorry if my story sounds confusing
Posted By: qwerty Re: /exit -d - 07/03/03 10:27 AM
In the meantime you can use this piece of code to do it:
Code:
alias exitd exit | .timer 1 0 sendkeys {ENTER}
alias sendkeys var %a = sendkeys $+ $ticks | .comopen %a WScript.Shell | if !$comerr { .comclose %a $com(%a,SendKeys,3,bstr,$1-) }


Calling /exitd would simulate hitting the Yes button in the confirmation dialog.
Posted By: SaX0n Re: /exit -d - 07/03/03 11:30 AM
Yeah right... but what if you dont have WSH installed? A lot of Anti-Virus programs encourage you to disable it if it is installed. And it isn't pre-installed on Win95/Win98 it's an optional component. Im not sure about WinME. All these WSH solutions are cool, though not good for mass-distributed scripts.

It seems com isn't much use in mIRC without WSH. crazy
Posted By: qwerty Re: /exit -d - 07/03/03 07:40 PM
If they don't have WSH installed... the script won't work. There is no alternative for this particular problem atm, so it's better to make it work on some systems than none. Besides, if it doesn't work, no harm done, all the user has to do is press OK.

However, you do have a point about mass distributed scripts: there might be cases that the unexpected absense of WSH would lead to a 'major' bug in the script. So, the script should first check for the existence of WSH (there's $comerr and the Version property) before attempting to use it.
Posted By: demitrix Re: /exit -d - 31/08/03 06:27 PM
alias exitd {
quit
exit
}
© mIRC Discussion Forums