![]() |
Telelogic DOORS (steve huntington) | ![]() |
new topic :
profile :
search :
help :
dashboard :
calendar :
home
|
||
Latest News:
|
|
Topic Title: Import Word tables into DOORS Topic Summary: Created On: 28-Jul-2006 21:44 Status: Post and Reply |
Linear : Threading : Single : Branch |
![]() |
![]()
|
![]() |
|
We've been looking at creating a tool to import from Word, with object hierarchy and a few other things just the way we like them (neither of the built-in options does what we need). My design so far has been to go through the Word doc by paragraphs and copy each one over, while building object hierarchy (based on Word styles). Then I came across this post and have looked through Paul Tiplady's work. Very handy stuff.
The part I'm having trouble with at the moment is getting tables across cleanly. If I use the same method as for regular text paragraphs I get a few Word errors about the end of the row, and a flat hierarchy of DOORS objects for each cell. (Paul's script seems to do about the same.) So I figure we need to handle tables independently of paragraphs, which may or may not require changing the whole "for paragraph in doc" idea. So, has anyone been successful (in DXL or VBA) in getting Word tables into DOORS? In particular I'm struggling with: How do you find out if you're in a table, when you're looping through paragraphs? How do you proceed through the table cell-by-cell? How do you get the (formatted) text from Word cells into DOORS cells? If I can get a Selection object on a cell I can do a Copy on it and then do a MoveRight to get the next one, but I still get hung up on figuring out when I'm in a table.... Ideas from anyone? General comments or similar projects or just plain commiseration would be welcome too. Or tell me to go post to a VBA forum ![]() Chris |
|
![]() |
|
![]() |
|
Hi Chris,
excuse me, but the standard word export to DOORS is not enough for you? Did you ever try it? You can use it as being part of C:\Program Files\Telelogic\DOORS 7.1\lib\word\doors.dot or analoguous when clicking on the DOORS icon in Winword or Running macro "ExportToDoors". This one is respecting hierarchy etc. and especially tables! Please ensure that you use format styles like heading or at least levelling in your Winword document to let your module be arranged in a correct hierachical order. Is that an idea, to prevent you from reinventing the wheel? ![]() Regards Hubertus Edited: 31-Jul-2006 at 08:18 by Hubertus Grobbel |
|
![]() |
|
![]() |
|
Hi Chris,
to find out, if you are in a table is simpler, than you thought ![]() OleAutoObj selTables = selection."Tables"; if ((int selTables."Count") > 0) { // check, if selection is within a table // the selection is within a table cell } This code uses syntax provided by my include file posted here To get the table into DOORs may be your job ![]() What do you think about to copy and paste the hold table as OLE object into DOORs. This will prevent you from creating DOORs tables ![]() Greetings Reik ![]() ------------------------- Evosoft GmbH for Siemens Industry Sector Berlin, Germany Edited: 31-Jul-2006 at 08:06 by Reik Schroeder |
|
![]() |
|
![]() |
|
Thanks for the replies! I think I'm moving (slowly) toward something useful here...
Hubertus: Yes, I've tried the Word exporter macro, and I love how it gets the hierarchy. The big problem is that we have a lot of documents that DON'T use heading styles in a logical manner and so get really messy on import. For example, some of them use Heading 9 for the "highest level" heading--so it should map to a level 1 DOORS object, but the importer doesn't know that. The RTF importer script within DOORS has options to remap style levels and all but we don't want to have the extra trouble. Also, neither of them break objects up the way we'd like (which is generally at a blank line rather than one paragraph break). So, we want something that will simplify the process for our users and come out with a decent result 90% of the time. Long explanation, sorry ![]() Reik: That's great--it's about the same solution I hit upon after posting on Friday. Only I was using the paragraph Range rather than Selection.....I still need to figure out which I'd need to start with. I've got it going mostly, except the Copy method on a Selection chokes when there's no text selected (like when a cell is blank). I like the idea of copying and pasting the entire table as an OLE object, but I hadn't been able to figure out how. Do you have any ideas? That would really simplify things..... Thanks again, Chris |
|
![]() |
|
![]() |
|
Hi Chris,
if your users/customers do not discipline themselves in creating structured document surely any automatism will fail or will not be able to reach at least the 90 % you are claiming. Bye Hubertus |
|
![]() |
Telelogic DOORS
» DXL Exchange
»
Import Word tables into DOORS
|
![]() |
FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.