The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum for Programming
 LabTalk Forum
 Referencing Notes windows
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

CStorey

Canada
137 Posts

Posted - 03/18/2001 :  11:14:51 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Is there a way to loop over all Notes windows in an Origin project without knowledge of the names? Something like doc -e X {}? (If not I would like to suggest this to the developpers.) Even something that operated on all windows and used the Exist() command would be helpful.

Thanks for the help.
Craig

greg

USA
1379 Posts

Posted - 03/19/2001 :  2:57:27 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
There are no LabTalk functions to return Notes window names. You can (currently) only Create, Activate/Restore, Minimize, Maximize or Close Notes Windows. Using the exist function, you could test if a particular Notes Window exists. This means your only option at the moment is to use a strict convention and management scheme vis-a-vis Notes Windows. To do this, you must understand the automatic naming convention Origin uses:

window -new Notes BaseName;

If "BaseName" does not exist, then it is created.

If "BaseName" exists, then Origin will enumerate a number (#) from 1 until BaseName# does not exist and create it.

So until we have a function that returns Notes Window names, you can find the next available name with:


ii=0;
%A=BaseName;
if(exist(%A)==9) {
for(ii=1,done=0;done==0; ) {
if(exist(%A$(ii))==9) ii+=1; else done=1;
}
}
ii=;


If ii is zero, then the named window does not exist (an enumerated name might exist).

If ii is non-zero, then that number can be used to enumerate a new window.


Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000