![]() |
Telelogic DOORS (steve huntington) | ![]() |
new topic :
profile :
search :
help :
dashboard :
calendar :
home
|
||
Latest News:
|
|
Topic Title: Treeview Topic Summary: How to build up a treeview from a certain Project Folder ? Created On: 24-Sep-2007 14:08 Status: Post and Reply |
Linear : Threading : Single : Branch |
![]() |
![]()
|
![]() |
|||
Hi all,
i´m trying to build up a treeview from a certain Project Folder. The Treeview for the whole Database is working fine. But I want to build up the Treeview from a certain Project Folder. I don´t get it. If i replace the "/" with a Project Folder name like "/myProject" in the the fillTreeSimple2 function it doesnt´t shows me anything but with "/" it works ? THX
|
|||
![]() |
|||
![]() |
|||
You need to insert the project name into the tree first. Then call fillTreeSimple2() with the project name as the second parameter.
------------------------- Tony Goodman http://www.smartdxl.com |
|||
![]() |
|||
![]() |
|||
Thank you for your fast answer. But how to get the rest (Modules,Folders,Projects) under this "nod" ?
Is there a simple function or must I iterate over all Modules,Folders,Projects by Type and build the tree by Hand ? |
|||
![]() |
|||
![]() |
|||
Add the following lines to your script
------------------------- Tony Goodman http://www.smartdxl.com |
|||
![]() |
|||
![]() |
|||
Thank you for your reply. But it doesn´t work. :-(
fillTreeSimple2(targetList, "/", "Project") --> That works
It shows the whole database Tree
fillTreeSimple2(targetList, strSourceProjectName, "Formal") ---> Thats doesn´t work. Nothing is displayed.
strSourceProjectName really exists
|
|||
![]() |
|||
![]() |
|||
This code works for me.
I am using DOORS 8.1, but that should make no difference. Try the code here, unedited. ------------------------- Tony Goodman http://www.smartdxl.com |
|||
![]() |
|||
![]() |
|||
Hi,
I also use DOORS 8.1
But it won´t work. It shows me only the Project folder nothing more :-( .Strange.
Do you get Project as "root" with all folder and Projects below this root Project?
|
|||
![]() |
|||
![]() |
|||
It works for me and displays the entire project hierarchy. See the screenshot attached.
Are you definitely running the code pasted from here and not changed in any way?
------------------------- Tony Goodman http://www.smartdxl.com Edited: 25-Sep-2007 at 15:53 by Tony Goodman |
|||
![]() |
|||
![]() |
|||
I used the code from here and I don´t changed anything. Just copy and paste. It shows me only the Project Folder. I think the failure is somewhere in my dbtree.inc. But the function are called in the dbtree.inc.
Perhaps i should get a new one.
|
|||
![]() |
|||
![]() |
|||
Got it!
Well I think I have. This code will only work if the project is in the database root folder. I don't think it will work with nested projects. That's because it relies on the fullName of the item to locate where to insert it in the tree. The fullName goes back to the nearest ancester project, which is not necessarily the root. You could try modifying the code in dbTree.inc to use rootName_() instead of fullName() and see what difference that makes. Make a backup copy first! Not sure of the solution yet, but I will look into it. ------------------------- Tony Goodman http://www.smartdxl.com |
|||
![]() |
|||
![]() |
|||
Hi Utz,
Did Tony Goodman's last suggestion, regarding the use of 'rootname_()' work for you in the end. See the attached - we use 'rootname_(getparentfolder())' in our routines - allowing us to select a project which may or may not be nested within another project. Regarding the populating of the treeview under a specific folder or project, in the attached example I am only displaying my "Equipment" items. Anyway, this will hopefully show you how to obtain all other projects and/or folders under a selected project or folder (see 'if type(i) == folder or type(i) == project' condition in GetICDFiles procedure) . Regards, Chris.
|
|||
![]() |
Telelogic DOORS
» DXL Exchange
»
Treeview
|
![]() |
FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.