![]() |
Telelogic DOORS (steve huntington) | ![]() |
new topic :
profile :
search :
help :
dashboard :
calendar :
home
|
||
Latest News:
|
|
Topic Title: Problem with dateOf(Baseline b) Topic Summary: Returning current date Created On: 27-Aug-2007 18:11 Status: Post and Reply |
Linear : Threading : Single : Branch |
![]() |
![]()
|
![]() Answer: As Lou and Kevin say, you can only get that info with a "for baseline in module" loop. | |
![]() |
|
I've got an object history script (modified version of Michael Sutherland's) and when I put the Baseline number and date in the list view, I'm getting the current date for every baseline. I get a handle to the baseline using
Baseline b = baseline(major, minor, suffix) Then get the date with dateOf(b). The only things in between is checking if the baseline is already open, opening if it is not, and passing b to another method that takes it as a parameter. "b" doesn't get modified though. ------------------------- David Pechacek AAI Services Textron dpechacek@sc-aaicorp.com David.Pechacek@gmail.com |
|
![]() |
|
![]() |
|
David,
Without seeing your code this is impossible to troubleshoot. Are you using a for baseline in module loop? It doesn't sound like you are, and thus, b is not getting updated. Post your code, though, and we'll be able to help you more. Kevin ------------------------- Kevin Murphy http://www.baselinesinc.com The Requirements Management Experts |
|
![]() |
|
![]() |
|
No I'm not getting the baseline with a baseline in module loop. I'm manually loading each baseline with Baseline b = baseline(int major, int minor, string suffix). I notice in the DXL manual it says to use commands like dateOf(Baseline b), you have to use it in such a loop. I guess loading the baseline manually doesn't get the proper information.
So I added another Skip that holds the creation dates for the baselines. ------------------------- David Pechacek AAI Services Textron dpechacek@sc-aaicorp.com David.Pechacek@gmail.com |
|
![]() |
|
![]() |
|
Understand you can get a baseline handle with Baseline b = baseline(major, minor, suffix) even when there is no such baseline in the module. Try this code from an open module:
Baseline b = baseline(9,9,"") print "B is null = " (null b) "\n" it should come back false. Not sure what the early DXL folks were thinking when they came up with that. Yes, use a baseline loop when you are dealing with actual baselines. Be sure you never used nested baseline loops (such as I did when I had a library function with such a loop). To avoid that, stage baselines in a Skip list then loop through the List: Skip skpBLs = create() for bl in mod do { put (skpBLs, bl, bl) } for bl in skpBLs do { print major(bl) "." minor(bl) "<" suffix(bl) ">\t" (dateOf(bl)) "\n" } delete(skpBLs) - Louie |
|
![]() |
|
![]() |
|
I got the same problem.
The code look like: Baseline b = baseline (1, 3, "") // This returns false every time as the baseline OBJECT is // instanciated and never NULL. ('cuse spl'ng) print (null b) "\n" // This is the command you want if you need to see if the // baseline is good for the module you have open. // In this case, returns true if current Module have baseline 1.3. print baselineExists (current Module, b) "\n" //Now, the problem is that following code should display // the date the baseline was frozen. But instead it displays // todays date. print (dateOf(b)) "\n" //[sigh] However if you put the above code in a loop (as mentioned by Mr. Landale above) you get the expected result... Baseline b for b in current Module do { print (dateOf(b)) "\n" } So Louie Landale's post is right on the money. Mark it solved. Edited: 29-Aug-2007 at 15:31 by Norberto Silva |
|
![]() |
|
![]() |
|
As Lou and Kevin say, you can only get that info with a "for baseline in module" loop.
------------------------- David Pechacek AAI Services Textron dpechacek@sc-aaicorp.com David.Pechacek@gmail.com |
|
![]() |
|
![]() |
|
[duplicate post]
Edited: 29-Aug-2007 at 15:30 by Norberto Silva |
|
![]() |
Telelogic DOORS
» DXL Exchange
»
Problem with dateOf(Baseline b)
|
![]() |
FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.