Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

trap system tray error message (e.g. "No Disk" exception)

$
0
0
hello all,

I'm having a script running FileCopy function, where the target happend to be an unstable hard drive.

I can replace my hard drive (and I will soon), but this is not my concern.

when FileCopy fails, I can read the return code and work with it, and that's fine; but Windows tends to get in the way with a baloon tip saying: "AutoIt v3: Windows - No Disk". my concern is what happens when this script runs on some other computer in my enterprize and encounters the same issue. I want to trap the error before Windows starts alarming the end-user with spooky messages.

see attached file for screenshot of the error message.

I considered that the script will check drive status before filecopy, but this does not handle instability of hardware, just the media being ready / not ready.

any suggestinos are welcome (also, is there a way to display a screenshot in the thread text?)

thanks,
Or

Attached Thumbnails

  • autoit-disk-error.png

Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>