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: EXCEPTION ACCESS VIOLATION ERROR
Topic Summary:
Created On: 8-Aug-2005 21:14
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.
 8-Aug-2005 21:14
User is offline View Users Profile Print this message


Maria Manco

Posts: 12
Joined: 21-Jul-2004

We are getting an "Exception Access Violation Error" in just one of our modules.

The error ONLY occurs when a module is opened "read only" and then from inside the module, the mode is switched to "exclusive edit". The error does NOT occur when opened "exclusive edit" and then switched to "read only"

The error message refrences one of our custom scripts. This script is in many similar modules and does not cause a problem. The script just follows an outlink and displays in the source module the value of an attribute in the target module.

Once you click through the error, it does not cause a problem. In fact, the script copies the text as intended.

The error is referencing the last line in the last if statement --> obj.attrDXLName = strAttr



Here is our script.


/*
Copies a value from across an out-link, set the attribute name to that you wish to copy
*/


pragma runLim, 0
string strAttr = ""

const string S_ATTR_1 = attrDXLName
Link lnk

for lnk in obj -> "*" do
{
//does obj have link
tgtModName = fullName target (lnk)
if (!open module tgtModName)
{
read (tgtModName, false)
}

Object uTgt = target (lnk)
if ((uTgt != null) && (obj != null))
{
strAttr = strAttr "\n" uTgt.S_ATTR_1 ""
}
}

if (obj != null)
{
obj.attrDXLName = strAttr
}

-------------------------
Hello
Report this to a Moderator Report this to a Moderator
 8-Aug-2005 21:24
User is offline View Users Profile Print this message


Leidy Ramirez

Posts: 11
Joined: 15-Jun-2005

Because you can only modify the module when it is open on edit mode not read mode. Therefore, the last line obj.attrDXLName = sttrAttr is going to give you a runtime error when the module is open on read mode. Hope this helps, Leidy Ramirez
Report this to a Moderator Report this to a Moderator
 9-Aug-2005 19:52
User is offline View Users Profile Print this message


Maria Manco

Posts: 12
Joined: 21-Jul-2004

the problem is when we start in read-only and then switch to exclusive.

We do have lots of attribute DXL that works in read only mode.


Again, this is the only module that has this problem. All other modules have the same attributes as this one and do not have a problem.

-------------------------
Hello
Report this to a Moderator Report this to a Moderator
 17-Oct-2005 16:10
User is offline View Users Profile Print this message


Thomas Hebendanz

Posts: 3
Joined: 13-Jun-2005

You should also check for deleted target etc.
Report this to a Moderator Report this to a Moderator
 19-Oct-2005 15:34
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

In v6 I demonstrated some wierd bug in the "setExclusive" Telelogic DXL, invoked when you manually switch the edit mode from the module's "Edit" menu. The bug did something odd to the DXL environment such that no DXL would execute at all. I doubt telelogic fixed it. I ended up writing my own "SwitchOpenMode.dxl" that issues "isEdit" etc with "downgrade" commands.

Anyway, if this was my problem I'd think about some of the following: [1] is the parent module's attribute value also an attribute DXL (that is, is the source value from a grand-parent module rather than from a parent module)? [2] You may also have an issue with an empty attribute value as this causes constant updating of the Attribute DXL. Consider the following: if (!null strAttr) THEN obj.attrDDXLName = strAttr ELSE obj.attrDXLName = " " (a space). That will prevent update thrashing. [3] There may also be an issue where the current "obj" is being changed due to [1] above. Consider adding "Object oCurr = obj" at the top, then using oCurr throughout.

- Louie

PS: I notice all your displayed values will start with an empty line. A common technique is this: add string EOL = "" before the for link loop. Inside your update, change to "strAttr = strAttr EOL uTgt.S_ATTR)_1; then add "EOL = "\n". The effect will be that all values except the first are preceeded by an EOL.
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic DOORS forum.
There are currently 0 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 0 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.