mIRC Home    About    Download    Register    News    Help

Print Thread
#261023 18/07/17 09:11 PM
Joined: Aug 2003
Posts: 319
P
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
P
Joined: Aug 2003
Posts: 319
When on GETFAIL is called, is it possible to distinguish between the failure caused by the user clicking the cancel button and a comms failure.

(I want a script to ask the sender to retry if it is a comms failure but not if it is a user cancellation - so I need to be able to distinguish between them.)

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
You can check the value of $active. It's possible for there to be a false positive by someone happening to have the get window active when there was a comms failure, but that's not likely if the option is checked for automatically minimizing incoming dcc windows.

maroon #261032 19/07/17 09:39 AM
Joined: Aug 2003
Posts: 319
P
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
P
Joined: Aug 2003
Posts: 319
Originally Posted By: maroon
You can check the value of $active. It's possible for there to be a false positive by someone happening to have the get window active when there was a comms failure, but that's not likely if the option is checked for automatically minimizing incoming dcc windows.


The above suggestion is a good one, however "not likely" is perhaps a little strong, and good programming does not rely on uncertainties.

Also I am unsure whether GETFAIL is triggered if the user clicks cancel on the Accept / Ignore / Cancel message box (which is not a mIRC window).


Link Copied to Clipboard