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: Doors 8.1 Migration - DXL errors in Baselines
Topic Summary:
Created On: 19-Apr-2007 09:36
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.
Answer This question was answered by Tony Goodman, on Thursday, April 19, 2007 3:01 PM

Answer:
You could define the variable in startup.dxl.
 19-Apr-2007 09:36
User is offline View Users Profile Print this message


Jörg Werner

Posts: 24
Joined: 29-Jul-2005

Hello,

we want to migrate from Doors 7.1 to Doors 8.1.
One script, which is used in many modules and attributes, has a problem. A definition of a variable is missing and therefore I get an DXL error when opening the Modul.
Of course this can be fixed :-).

But I can fix this only for the current version and not for baselines. If I open a baseline or run the nice script "History of Objects" from Michael Sutherland I get a lot of DXL errors.

Any idea how we can solve the problem?

  Thanks and kind regards,

            Jörg
Report this to a Moderator Report this to a Moderator
 19-Apr-2007 09:56
User is offline View Users Profile Print this message


Tony Goodman

Posts: 1098
Joined: 12-Sep-2002

Answer Answer
You could define the variable in startup.dxl.

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


Jörg Werner

Posts: 24
Joined: 29-Jul-2005

Thanks Tony!

Great idea.

Although I've no write access to startup.dxl:  I've just added a command line argument

   -dxl "Object othero"

and now it works fine.

   thanks a lot,

             Jörg
Report this to a Moderator Report this to a Moderator
 19-Apr-2007 19:55
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

Doh!!!

Hello again to the nonsense of 'implicitely defined variables'. That 'nice' feature of modern languages has probably causes more havok than any other. I notice a WHOLE BUNCH of telelogic written code that uses it. In this case they say 'othero = target(l)' which used to mean only 'Object', but they added a new perm to v8.1 called 'target' and now the old code, with implicit variables, doesn't work since 'target' now means ModName_ I think.

Look for 'AutoDeclareSet' in the DXL forums for a script that will turn it on and off dynamically. It was written by a very clever person. Turn it on before opening the module, and advise other folks to do the same. Be sure to turn it off before developing any DXL. I'd put that code into your dxl\addins\user folder.

The startup.dxl solution requires everyone who opens the module to do it.

Another solution would be to define a pre-open module trigger for this module that puts 'Object othero' into the top context, I think with the 'evalTop' command. The other clever folks who've actually done stuff like that will want to comment on that. Goodman?

- Louie
Report this to a Moderator Report this to a Moderator
 20-Apr-2007 20:10
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

Did a little further investigation and my previous post was slightely incorrect: there is no new 'target' perm in v8.1 but they reversed the order of precedence in them. The following code demonstrates this point. When its run in both v7.1 and v8.1 with AutoDeclare off, you get this DXL error among others:

-E- DXL: <Line:11> undeclared variable (othero)

With AutoDeclare on and run in v7.1, you get these errors:

-E- DXL: <Line:14> incorrect arguments for function (nStr)
-E- DXL: <Line:15> incorrect arguments for function (nMN)

With AutoDeclare on and run in v8.1, you get these errors:

-E- DXL: <Line:13> incorrect arguments for function (nObj)
-E- DXL: <Line:15> incorrect arguments for function (nMN)

Thus, 'target(Link)' defaults to return type 'Object' in v7.1 (making those layouts work), but defaults to type 'string' in v8.1, making those layouts fail since 'othero' gets defined as type 'string' not 'Object' as desired.

Looks like we need to update all our analysis Wizard created layouts. I hate it when that happens.

- Louie
Report this to a Moderator Report this to a Moderator
 23-Apr-2007 23:56
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

Did you get the original errors in Analysis wizard DXL, or did you perhaps your own DXL and used variable 'othero'?
Report this to a Moderator Report this to a Moderator
 28-Apr-2007 08:37
User is offline View Users Profile Print this message


Jörg Werner

Posts: 24
Joined: 29-Jul-2005

It was my own code, where I forgot to declare a variable. Cheers, Jörg
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic DOORS forum.
There are currently 2 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 2 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.