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: softDelete(module)
Topic Summary:
Created On: 2-Sep-2004 16:35
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 Hugh Johnson, on Wednesday, September 8, 2004 10:11 AM

Answer:
Hi Louie,

I have previously tried closing all modules and deleting all linksets, but a persistant reference to the link module remains from a formal module that no longer has links or linksets and is closed! Another post explains this problem better....

Thanks for the help

Hugh

http://support.telelogic.com/en/doors/forums/messageview.cfm?catid=17&threadid=1746
 2-Sep-2004 16:35
User is offline View Users Profile Print this message


Hugh Johnson

Posts: 27
Joined: 5-Aug-2004

Hi all,

Having some problems deleteing a link module from the database, the code that i've used is roughly as follows:-

save(linkMod)
close(linkMod)
softDelete(linkMod)

So i've made sure that link mod is up to date and closed before deleting it. However when I run the code in question I get an error saying 'cannot delete open item' which seems a bit strange given that I've closed it the line before! Also just before the close there is only one open reference to the link module. The only thing i can think of is that although the actual links themselves are previously deleted the linkset in the link module still exists.

Any ideas?

Hugh



-------------------------
Hugh Johnson

Westland Helicopters Ltd.
myurl
Report this to a Moderator Report this to a Moderator
 2-Sep-2004 21:17
User is offline View Users Profile Print this message


Dennis Lockshine

Posts: 113
Joined: 7-Apr-2003

Hugh,

When you open any formal module, the link module(s) that contain the linksets for any of its outgoing links are also opened, non-displayed. You can verify this by going into the "Manage Open Modules" from the Tools menu in the Project Manager window (the main window that gets opened when DOORS starts).

In order to close the link module, you would probably need to first close any formal modules that cause the above condition to occur.

-Dennis
Report this to a Moderator Report this to a Moderator
 3-Sep-2004 12:07
User is offline View Users Profile Print this message


Hugh Johnson

Posts: 27
Joined: 5-Aug-2004



<< In order to close the link module, you would probably need to first close any formal modules that cause the above condition to occur. >>



Having done some further work I now delete all links all the link sets, the objects that referred to the link sets and closed their parent modules. However in the Manage Open modules window the link module persists with two references. One of these may be my fault but the other reference is untraceable. I perform a close on the link module and this removes one of the references but the other perists. Therefore softDelete module fails saying:-



<< -R-W- DXL: <saveutilities.inc:902> deleting module 'rg' fails: Cannot delete open item >>



This 'mysterious' reference can be closed manually through manage open modules, but does not seem to be closed by the DXL script, therefore :

    Does close(module) only close one reference to the module or all references


Hugh

-------------------------
Hugh Johnson

Westland Helicopters Ltd.
myurl
Report this to a Moderator Report this to a Moderator
 3-Sep-2004 17:13
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

Once its closed the Module handle is supposed to be invalid. I'm also surprised your softDelete(linkMod) function doesn't generate an error, since the command takes a NameMod_ not a Module parameter. Anyway, try this:
string NameFull = fullName(linkMod)
close(linkMod)
softDelete(module NameFull)

- Louie
Report this to a Moderator Report this to a Moderator
 6-Sep-2004 08:40
User is offline View Users Profile Print this message


Hugh Johnson

Posts: 27
Joined: 5-Aug-2004

Thanks for the replys guys,

I tired a very similar thing to what you said Louie, but still there was a persistant reference to the link module. To put the problem in context the softDelete is within a save function which synchronises my doors database to a rather large nested array. When i go into the save function i was trying to respect the display set on my GUI in order to make the save as unobtrusive as possible, however this meant that when i went into the save, there was a formal module open that had a link through the link module i was trying to delete. Although i then deleted the link, doors wasn't clever enough to remove the persistant reference to the link module that the link had caused. The result of this is that in order to be able to succesfully delete the link module i have to first close the formal modules that my GUI is holding open. This is a problem for the user as it might mean digging through 6 or 7 levels of nesting to find the item they were working on!

-------------------------
Hugh Johnson

Westland Helicopters Ltd.
myurl
Report this to a Moderator Report this to a Moderator
 7-Sep-2004 22:20
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

Doh!

You cannot delete an open module. Formal modules are closed when you "close" them but link modules remain open so long as there is ANY formal module open that uses it. Try this: open a formal with links, then look at the Tools>>Manage Open Modules from the DOORS Explorer. See the extra open modules.

Close all your modules. Or delete ALL the linksets. Then try to soft-delete the link module.

- Louie
Report this to a Moderator Report this to a Moderator
 8-Sep-2004 10:11
User is offline View Users Profile Print this message


Hugh Johnson

Posts: 27
Joined: 5-Aug-2004

Answer Answer
Hi Louie,

I have previously tried closing all modules and deleting all linksets, but a persistant reference to the link module remains from a formal module that no longer has links or linksets and is closed! Another post explains this problem better....

Thanks for the help

Hugh

http://support.telelogic.com/en/doors/forums/messageview.cfm?catid=17&threadid=1746

-------------------------
Hugh Johnson

Westland Helicopters Ltd.
myurl

Edited: 8-Sep-2004 at 10:13 by Hugh Johnson
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.