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: Detecting Changes in OLES
Topic Summary: A few mechanisms/ideas for detecting change in OLES
Created On: 21-Dec-2005 14:06
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.
 21-Dec-2005 14:06
User is offline View Users Profile Print this message


Richard Good

Posts: 152
Joined: 22-Mar-2005

I have been asked to find some mechanism to report changes in OLEs between the last baseline and current. This forum has been a good source of ideas and help in completing this task. I have had a few (hopefully) good ideas that perhaps need a bit more work/ thinking about. I hope to eventually create an attribute with the red lined differrences for each OLE, perhaps using the Word compare documents function. Anyway here's my first attempt, if you take the code and improve it/ correct it then please post it back.

-------------------------
Regards,

Richard Good
Report this to a Moderator Report this to a Moderator
 21-Dec-2005 22:49
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

I had some good-enough luck as follows: retrieve the richText of both attributes. Retrieve the raw text of both attributes. If the length of the rich text was very large (>100,000 bytes) then it contains an OLE. If the Raw texts were the same but the rich texts were different LENGTHS, then there must be a change in the Ole.

This fell apart when I discovered the following:
FromValue = objFrom."Object Text"
objTo = Value
ToValue = objTo."Object Text"
if (FromValue != ToValue) ..

Turns out these were rarely the same. The rich text markup doesn't match even if the results of the markup DO match (one is \b BoldText \b0, and the other is {\b BoldText}. I overcame this rather annoying feature by creating a RichText dialog element in a dialog box, setting the value to the DBE, then immediately reading it from the DBE. This seems to work.

- Louie
Report this to a Moderator Report this to a Moderator
 22-Dec-2005 10:35
User is offline View Users Profile Print this message


Richard Good

Posts: 152
Joined: 22-Mar-2005

Louie,
That seems (on the face of it) to be a good simple solution and if a few OLEs that have not changed are flagged as changed I'm not sure I'll lose too much sleep (if you are comparing the same object in differrent baselines this can't happen that often, surely?), the DBE thing sounds a bit OTT, can't you achieve the same using one of the richText commands like richTextFragment. Not sure I should be using words like OTT when I have batchfiles and diff utilities and Word coming in at all angles! But I do have the excuse that I'm working towards creating an attribute which displays the differrences for both the text and the OLE's, and more importantly all my customers have gone home for christmas so I can do whats interesting rather than whats pressing! Have a good Christmas.

-------------------------
Regards,

Richard Good
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.