Make macro beep on error and continue

Discussion & Support for xplorer² professional

Moderators: fgagnon, nikos, Site Mods

Post Reply
User avatar
pschroeter
Silver Member
Silver Member
Posts: 283
Joined: 2007 Jan 27, 00:46

Make macro beep on error and continue

Post by pschroeter »

I figured out ERRORSTOP 0 makes a macro not hang up on an error. Is there a way to make a macro exit AND beep to let me know the error has happened?

I have the following macro that just swaps the panes in two pane view.

ERRORSTOP 0
command 32869 This replaces a Menuhack command I no longer need, thank you.

Since my open Dual button and Swap Pane buttons look similar, it kind of lets me know I pushed the wrong button if I meant to push the Dual button.

It might be nice if I could write something like
ERRORSTOP 0 BEEP
With BEEP being an optional argument.
User avatar
nikos
Site Admin
Site Admin
Posts: 15771
Joined: 2002 Feb 07, 15:57
Location: UK
Contact:

Re: Make macro beep on error and continue

Post by nikos »

when you turn off errors, you are supposed to check for errors yourself after each command that is uncertain. E.g after COMMAND you can put

Code: Select all

ERRORSTOP 0
 command xxx
JUMPOK no_error
message error!
LABEL no_error
so in case of error you would see an error message
Post Reply