Welcome to Telelogic Product Support
  Home Downloads Knowledgebase Case Tracking Licensing Help Telelogic Passport
Telelogic DOORS (steve huntington)
Decrease font size
Increase font size
Topic Title: DXL Input Arguments
Topic Summary:
Created On: 21-Apr-2005 21:02
Status: Post and Reply
Linear : Threading : Single : Branch
Search Topic Search Topic
Topic Tools Topic Tools
Quick Reply Quick Reply
Subscribe to this topic Subscribe to this topic
E-mail this topic to someone. E-mail this topic
Bookmark this topic Bookmark this topic
View similar topics View similar topics
View topic in raw text format. Print this topic.
 21-Apr-2005 21:02
User is offline View Users Profile Print this message


R Wheeler

Posts: 2
Joined: 21-Apr-2005

I can start DOORS from the command line using the -dxl command line switch:

"c:\Program Files\Telelogic\DOORS 7.1\bin\doors.exe" -D "#include \"c:/Documents and Settings/DXL/test.dxl\""

In that same command line, I want to be able to pass a section number (ex. "3.1.2") as a string to the DXL script.  Syntactically, how do I pass a string to a startup executed dxl script?  How do I get the passed arguments into the script?  I am looking for something like args.

Also, can anyone tell me how to goto to a given section (ex. "3.1.2")?  I have started by:

Module m = read("/test/specification_doc",true)
findReplaceModule_ = current
evalTop_ "findReplaceGoto_ tabGoto_"

Any information regarding evalTop_ and other commands like this that are not in the DXL or DOORS manuals would be greatly appreciated also.

Thanks in advance!

Report this to a Moderator Report this to a Moderator
 22-Apr-2005 08:42
User is offline View Users Profile Print this message


Tony Goodman

Posts: 1098
Joined: 12-Sep-2002

The attached code is a little function to go to an object with a specific attribute value. This will work for section numbers too.



-------------------------
Tony Goodman
http://www.smartdxl.com
Report this to a Moderator Report this to a Moderator
 22-Apr-2005 12:56
User is offline View Users Profile Print this message


R Wheeler

Posts: 2
Joined: 21-Apr-2005

Thanks Tony I learned yesterday that one cannot 'yet' pass arguments to a dxl script. So, with your answer I only have one unanswered question. Do you know anything about evalTop_, tabGoto_, etc? They sound like gui control; the equivalent of activating and manipulating guis with a mouse click. Do you know if they are documented anywhere? Thanks Again!
Report this to a Moderator Report this to a Moderator
 22-Apr-2005 14:39
User is offline View Users Profile Print this message


Tony Goodman

Posts: 1098
Joined: 12-Sep-2002

string eval_(string dxl)

This perm executes the dxl string parameter within its own context (scope). This means that any variables declared or values set will not be available outside (i.e to the calling function). The evaluation takes place AFTER the current dxl finishes execution. In other words you cannot use eval_() to do something and then check the results.

The return value is set by using return_(string) anywhere within the dxl. return_() does not force a return as you might expect, but just sets the value that is reurned when executeion completes.

string evalTop_(string dxl)

This is similar except that the dxl is executed in the top context. This has the same effect as running dxl from startup.dxl for example. Variables and functions declared in the top context are globally available in any context.

tabGoto_ is an int constant.
findReplaceModule_ is a Module variable.
findReplaceGoto_(int) is a function.
Thse are defined within the DXL code for the builtin find and replace functions.
These files are encrypted, so are of no use to you in your own dxl.




-------------------------
Tony Goodman
http://www.smartdxl.com
Report this to a Moderator Report this to a Moderator
 22-Apr-2005 15:01
User is offline View Users Profile Print this message


Dirk Plaschke

Posts: 103
Joined: 17-Sep-2002

You can pass your arguments via a batch variable and read this variabl from the dxl script.

the batch:

@echo off
set DOORS_PARM=%1
D:\usr\bin\doors7\bin\doors -u <user> -P <passwd> -D "#include <T:\doors\dev\src\doorsParameters.dxl>"

the dxl:

string s = getenv("DOORS_PARM")
infoBox(s)

usage:

\doors\dev\src>doorsParameters "Hallo, DOORS."



-------------------------
Dirk Plaschke
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic DOORS forum.
There are currently 1 users logged in.
The most users ever online was 15 on 15-Jan-2009 at 16:36.
There are currently 0 guests browsing this forum, which makes a total of 1 users using this forum.
You have posted 0 messages to this forum. 0 overall.

FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.