![]() |
Telelogic DOORS (steve huntington) | ![]() |
new topic :
profile :
search :
help :
dashboard :
calendar :
home
|
||
Latest News:
|
|
Topic Title: Anyone tried the AutoRun or Button Bar? Topic Summary: Created On: 6-Nov-2004 00:44 Status: Post and Reply |
Linear : Threading : Single : Branch |
![]() |
![]()
|
![]() Answer: The error message is spurious. You cannot define the mapping function in this file, or include a file that contains it. The menus are "built" once when you start DOORS. But the mapping functions are executed when required (i.e. the menu option is displayed), so the mapping function needs to be available. Declare your mapping functions in the top context by inclusion in startup dxl for example. | |
![]() |
|
I am trying to do two things and I'm not sure which one is failing. I put a dxl file in \lib\dxl\config\formalFiles. The file is executed, and it displays a new toolbar, but I constantly get this error:
-R-E- DXL: Backtrace: -R-E- DXL: I am assuming I am either incorrectly creating a button, or I need to return some value at the end of my dxl script. I tried returning several values, to no avail. My script is attached. I couldn't find ANY documentation relating to the auto execution of files. ------------------------- Shawn Stepper shawn.e.stepper@wellsfargo.com |
|
![]() |
|
![]() |
|
Hi Shawn,
in looking into your request for exec type functionality, I decided to knock up an example of adding a buttonbar to a dialog box. However, I get the same problem as you are seeing, with an incorrect return error. I have contacted Telelogic support regarding this and am awaiting their answer. Here's the example I created. When the "hello" dialog is closed, the error is reported: DB dlg = centered "Example BB" startConfiguringMenus dlg createButtonBar createItem(menuAvailable_, null, null, null, null, folderOpenIcon, null, null, null, "C:\\hello.dxl") end buttonbar show dlg the contents of hello.dxl is DB hello = centered "hello" block hello |
|
![]() |
|
![]() |
|
The error message is spurious.
You cannot define the mapping function in this file, or include a file that contains it. The menus are "built" once when you start DOORS. But the mapping functions are executed when required (i.e. the menu option is displayed), so the mapping function needs to be available. Declare your mapping functions in the top context by inclusion in startup dxl for example. ------------------------- Tony Goodman http://www.smartdxl.com Edited: 8-Nov-2004 at 16:59 by Tony Goodman |
|
![]() |
|
![]() |
|
Here's the fixed example of using a button bar in a user dialog box. Rather than specify a new mapping function, it uses the Telelogic defined "alwaysOn" mapping function, so the startup.dxl doesn't need updating.
Just a shame that the button bar can only use pre-defined icons. :-( ----------------------- DB dlg = centered "Example BB" startConfiguringMenus dlg createButtonBar createItem(alwaysOn, null, null, null, null, folderOpenIcon, null, null, null, "C:\\hello.dxl") end buttonbar show dlg the contents of hello.dxl is DB hello = centered "hello" block hello |
|
![]() |
|
![]() |
|
Defining the callback function in a dxl file in the "startupFiles" folder allows use of the button bar. But the problem with it is that the function scope is global, instead of per module. I want to have functions that are scoped for the module, when the module is opened.
For example, if I define an integer in the startupFiles script, and increment it each time my button is clicked in a formal module, the variable value is the same across modules. Anyone know how to scope the variables and functions to the module? Can it be done by overloading the functions? ------------------------- Shawn Stepper shawn.e.stepper@wellsfargo.com |
|
![]() |
|
![]() |
|
overloading isn't an option.
I would suggest creating skiplists in the global context with a module identifier as the index. |
|
![]() |
|
![]() |
|
I was hoping to avoid that, but I guess it wouldn't be too much more complicated. Probably a skip list where the key is the module id and the value is another skip list.
Thanks for the advice! ------------------------- Shawn Stepper shawn.e.stepper@wellsfargo.com |
|
![]() |
Telelogic DOORS
» DXL Exchange
»
Anyone tried the AutoRun or Button Bar?
|
![]() |
FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.