Reply to note from Edward Mendelson <em36@xxxxxxxxxxxx> Tue, 10 Jan 2023 15:29:21 -0500 > If you could provide a beginner-level step-by-step, Pardon my jumping in, but the original question is deceptively *not* beginner-level. For starters, a <PR...> statement by itself will not pause a program, as Edward observed. There *is* another embedded command, <PA...>, that does insert a pause -- but only during the *printing* of a file, so it's not apropos. Unfortunately, there is no single built-in command that will pause an XPL program upon encountering an error, much less report what the error is and where in the subject code it occurred. For that, you need some XPL. The attached PAUSE.XPL (also available at https://ammaze.net/xywwweb/dls/pausexpl.zip) describes a fairly simple way of preparing XPL code to do just that. But wait, as they say in the late-night TV commercials, there's more. The procedure in PAUSE.XPL traps "errors" in the technical sense, i.e., any directive that sets XyWrite's error flag, <ER>. But not every message emanating from an XPL program signals an error so narrowly defined. For example, the mysterious "vDosPlus only" message that Edward has been trying to debug originates in one or another U2 routine (source moi) designed to run specifically under vDosPlus. It's not triggered by the <ER> flag but by a test for the presence in Save/Get 652 of a string like "VDP" -- not an error at all, just a simple True/False condition. I've been trying to chase down the cause of those pesky, false-positive "vDosPlus only" messages. I've issued an update to U2 (2023-01-10) which attempt to do so. It's available here: https://ammaze.net/xywwweb/dls/XYWWEBU2.ZIP Feedback will be appreciated. -- Carl Distefano cld@xxxxxxxxxx
Attachment:
pausexpl.zip
Description: Binary data