[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

Error checking in XPL




I'm in the process of moving lots of stuff from Agenda (memory and
resource hog, alas) and into one or two Xywrite files, and in hope of
automating the process I've got one or two XPL questions. What I'd
like to do is come up with a program (thence to put onto a key) which
will call my "agenda" file up -- *but,* in case the file is already
open in another window, switch me to that window. Of course, the error
message goes:

	File is already open--open again? (Y)es,(N)o,(G)o,(R)ead

and so what I'd like to do is have the program "press G" is the file's
already up.

I guess it's going to be something like:

	BC ca c:\xy4\agendaXC ==?>G

but not only am I certain that's really bad xpl syntax, I have no idea
what the ER value for the "File Already Open" error is (and I am having
a bit of a tough time figuring out how to get it). Once I get that
running I'm hoping to start invoking the smartset search backwards and
forwards at the same time utility to make some use of it.


The other question I've got is surely a long shot: Since I tend to have
several Xy sessions open, does anyone happen to know whether there's
any way to ensure that if a file is opened in one session, it can only
be called up in read-only mode if it's called up in another?

-Rafe T.
raphaelt@xxxxxxxxxxxxx
http://www.ray-field.com