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: Automatically run a script
Topic Summary:
Created On: 14-Mar-2006 12: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.
 14-Mar-2006 12:02
User is offline View Users Profile Print this message


Tuomas Iivarinen

Posts: 2
Joined: 21-Nov-2005

Hello, Is it possible to automatically run a dxl-script, when user e.g. selects specific module / view in module etc. Is there some way to do this? Thanks, Tuomas
Report this to a Moderator Report this to a Moderator
 14-Mar-2006 14:15
User is offline View Users Profile Print this message


Eric Piallat

Posts: 33
Joined: 26-Jan-2004

This mechanism is called a "trigger" in DOORS. Please refer to the "Triggers" chapter in DOORS DXL Reference Manual.

-------------------------
E. Piallat
CeBeNetwork
Report this to a Moderator Report this to a Moderator
 14-Mar-2006 16:36
User is offline View Users Profile Print this message


Paul Worrall

Posts: 87
Joined: 30-Sep-2003

The only events you can attach triggers to are:

Module Open
Module Close
Object Open (= starting an in-line edit by double-clicking in a column)
Object Sync (= making a different object current)
Attribute Modify
Report this to a Moderator Report this to a Moderator
 14-Mar-2006 18:24
User is offline View Users Profile Print this message


cliff Bly

Posts: 58
Joined: 11-Apr-2003

Applying a trigger would be one way however, the original question is not clear to me.
1. Do you want something to happen when a user selects a particular view?? If you want something displayed, then create a view with a column containing a layout dxl. I would suggest making the dxl simple. Don't use the dxl to set other attributes or to do non-display actions.
2. If you want a dxl to run when a module is opened -- Another way would be to put a dxl into the folder doorsHome/lib/dxl/config/formalFiles. ANY file in that directory will run as a dxl when a formal module is opened. If you want the dxl to run for all users, either define doorshome to be on a network or you will have to copy that file to all clients.
WARNING - I find that a complex dxl involving dialog boxes, etc can crash DOORS. This is probably because some global values have not been set when the dxl is run. Before trying this I would suggest setting up a test database to try it. Remember, this affects ALL formal modules. If you want a dxl to run for a specific module, you will need a conditional statement at the start of the dxl. I don't use this feature and I do not recall where it was mentioned.

-------------------------
Cliff Bly
Report this to a Moderator Report this to a Moderator
 14-Mar-2006 18:24
User is offline View Users Profile Print this message


cliff Bly

Posts: 58
Joined: 11-Apr-2003

Applying a trigger would be one way however, the original question is not clear to me.
1. Do you want something to happen when a user selects a particular view?? If you want something displayed, then create a view with a column containing a layout dxl. I would suggest making the dxl simple. Don't use the dxl to set other attributes or to do non-display actions.
2. If you want a dxl to run when a module is opened -- Another way would be to put a dxl into the folder doorsHome/lib/dxl/config/formalFiles. ANY file in that directory will run as a dxl when a formal module is opened. If you want the dxl to run for all users, either define doorshome to be on a network or you will have to copy that file to all clients.
WARNING - I find that a complex dxl involving dialog boxes, etc can crash DOORS. This is probably because some global values have not been set when the dxl is run. Before trying this I would suggest setting up a test database to try it. Remember, this affects ALL formal modules. If you want a dxl to run for a specific module, you will need a conditional statement at the start of the dxl. I don't use this feature and I do not recall where it was mentioned.

-------------------------
Cliff Bly
Report this to a Moderator Report this to a Moderator
 23-Mar-2006 19:56
User is offline View Users Profile Print this message


Kevin Murphy

Posts: 206
Joined: 15-Jul-2005

I wanted to respond to something Cliff said. It may be a tangent, but it's caused me some problems.

If you set DOORSHome to be on a network drive, keep in mind that patching DOORS on a local drive will then cause your files on the network drive to be out of sync. This can cause all sorts of weird things to happen. I had a user who couldn't do a simple Control-F or Control-G without crashing his client.

If you're going to run DOORSHome off of a network, you must work much harder to keep all files current.

-------------------------
Kevin Murphy
http://www.baselinesinc.com
The Requirements Management Experts
Report this to a Moderator Report this to a Moderator
 28-Mar-2006 20:05
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

I don't think you can simply redirect your "$home" to be on a network drive. When you install DOORS, instead of installing the "DOORS Client" you install a "Workstation Client", which points your DOORS to the network.

- Louie
Report this to a Moderator Report this to a Moderator
 28-Mar-2006 23:34
User is offline View Users Profile Print this message


Kevin Murphy

Posts: 206
Joined: 15-Jul-2005

Louie,

Check the help documentation for the -HOME command line switch. There's the database IP address, and then the -HOME switch. Two separate things.

Kev

-------------------------
Kevin Murphy
http://www.baselinesinc.com
The Requirements Management Experts
Report this to a Moderator Report this to a Moderator
 5-Apr-2006 21:02
User is offline View Users Profile Print this message


Robin Riley

Posts: 4
Joined: 15-Aug-2003

It seems we got off track from Tuomas' initial question. I believe what he is asking - and what I'd like to figure out how to do as well - is have a DXL script automatically run when the user loads a particular view. Yes there are triggers but there is no way (that I've found) to attach a trigger to the "load a view" event because there is no "load a view" event. Does anyone have any ideas how to go about accomplishing this?

-------------------------
--------------------------------------
Robin Riley
Motorola, Inc
Robin.Riley@motorola.com
Report this to a Moderator Report this to a Moderator
 17-Jul-2006 20:32
User is offline View Users Profile Print this message


Scott Boisvert

Posts: 348
Joined: 14-Apr-2006

I'm also looking for the answer to this question as I have a similar problem. Not with switching a view, but with editing an object attribute.  I could set up a trigger for the whole object, but then the users would have to set the attribute everytime they edited the object.....not cool.  I want the script to run only when a specific attribute is being edited.



-------------------------
Scott Boisvert
Engineering Tools Administrator
L-3 Communications - Avionics Systems
scott.boisvert@l-3com.com
Report this to a Moderator Report this to a Moderator
 17-Jul-2006 23:23
User is offline View Users Profile Print this message


Kent Power

Posts: 18
Joined: 28-Apr-2005

See the section on trigger definition in the dxl reference manual.  One can associate execution of a script with modification of an object attribute.  The attached code gives an example. The attribute "Req't" is specified, as well as post-modification execution.  Specification of a priority allows the dxl environment to decide which trigger script to execute if a certain set of circumstances meet the conditions of more than one trigger.
Report this to a Moderator Report this to a Moderator
 18-Jul-2006 20:46
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

We've used a permanant pre-save-attribute trigger, whose purpose was to verify the new value as being valid and either allow or disallow the change to take affect. This trigger fires when the user clicks out of the column in question. I don't think it works for editing attributes from the Object properties dialog, nor from dxl assignment commands.

There is no post-edit-attribute trigger that would, for example, detect when the user started to edit a value in a column, and display some dialog with valid options for the user.

- Louie
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.