Abort a command button

Hah! I must be the only one to ever write non-perfect code the first time around.

So I need an abort button, for stopping the code in a command button from proceeding any further. That's for testing the code.

// Yes, I know about the double-slash comment maker to comment out a command while testing.

But when you have 107 lines to comment out when testing a command button, it gets tedious. (I've actually written Macro Express macros to put // double slashes in front of 10 lines at a time. And even that gets tedius.)

(Now I have nothing against tedium, except ... well, hell, no, yes, I DO have something against tedium. I takes up too much time!

So, is there a command? Might it be "Abort"? "Cancel"? "End-this-thing-now"? "Stop"? "Stop. No, really. Stop!"? "Go to :End"? (Uh, no, because I've tried those.) They don't work.

Ctrl-Z?

Can anyone help? I'd say I'm at wit's end, only I don't recall ever meeting wit's start. I guess that's why I'm witless.

And forgive me if the answer's obvious. I have a fantastic ability to overlook the obvious. Subtleties, I find in an instant. Obvious things, never, not in a million years. I can't even right now think of the word for things that are obviousl All I can think of is "obvialities", which I don't think is a word. Oh please, God, make it not a word.

See? I need help.

-- Steve

107 lines in a command button? Is that a script or just native DO commands added up?

Anyway, I've also found myself in situations where I wanted to stop a button or script from running now!.
Some kind of "Stop" button for all things currently in progress is exactly what I whished for as well! o)

You could use @if:$moo or @if:$variableThatDoesntExist or similar to stop the rest of the command being run, unless there are other @if type things in the lines you want to disable.

But if it's 107 lines and/or already using conditional logic, switching to a script probably makes sense anyway, and then you have lots of options for skipping blocks of code.

Mr. Tbone, I'd have to say it's a "dramatic enhancement", for effect. (I shouldn't do that.)

But I have had DOpus buttons that had 20 lines. E.g., open my text editor so I can make notes about what I'm doing, go to a folder, auto-size the columns, turn on the viewer pane, size the viewer pane, turn off the folder tree, turn off a floating toolbar, turn on a different toolbar, filter for *.odt files older than 2 days, put them in size order, send out for pizza, copy the subset of those files with "hamilton" and "burr" into a collection, open a new lister on that collection, fix Merle's flat tire, add date info into the filename (whereas, say, Bobby.odt becomes Bobby_2016-12-27.odt), backup my DOpus configuration, and so on.

Your need sounds just a little bit different from mine, yet solutions to each problem would be helpful. I'm in need of something like a breakpoint, where the running of the program/script/command list simply stops at a predetermined place. It sounds like you're in need of a fire extinguisher, where when you notice your script is making your laptop burst into flames, you can issue some keystroke command to kill the script right then and there.

Both would be useful additions. (For all I know, they already exist. That's why I was asking.)

I know Leo's sitting there shaking his head. Sorry, Leo, I've done my due diligence trying to find an answer via Google, for about half an hour, but came up empty. So I'm throwing myself upon your benevolent mercies. Thanks.

-- Steve

And of course the moment I finish typing, I discover Leo's already answered me. Thanks, Leo. I'll give those a try. (I've no doubt they'll work.)

By the way, I've been using DOpus for over 15 years now, maybe even closer to 20 (?), but I've never really noticed those @ commands. I've known about a few of them, such as @nodeselect, but when did conditionals become part of the mix? Mind you, I'm not complaining, not at all. Just a little embarassed that I hadn't noticed something like that.

They're pretty old now. Can't remember when they were added exactly but it was several years ago.

That's because they just recently removed the "@hidefromsglamantia" modifier from the manual.