Got my first exposure to DXL today... pretty cool stuff!
Category IBM/Lotus
As I mentioned a couple days ago, I am working on a solution to a problem at work involving Google indexing of Domino web pages with collapsed sections. The consensus was that DXL was the way to go, so I started my foray into uncharted (for me!) territory. By the time the day was done, I had an agent that exports selected documents to an output file, creates a modified file with updated expand/collapse section settings, and then imports that modified file back into the database. I had to piece it along as I went, working slowly but surely through each small chunk of processing logic. The only problem I've seen so far is with sections that start with bullets. It seems like the import routine sticks a empty bullet point at the start of the list. Don't know why, but it does...
Anyway, special thanks go to Mr. DXL, Mac Guidera, who provided me with some email direction and encouragement. I was feeling a bit guilty for not trying to use the NotesXSLTransformer class to do it all without file input/output. But I'm having a really hard time wrapping my mind around XSLT. Mac said that for what I was doing, XSLT was overkill. So I feel better about my approach now. :) Plus, I figure this way I have a before and after file snapshot of what happened. Any spin to help me sleep at night...
Anyway, if you want to see what I did and make fun of my code, check out the Read More... I'm sure I'll look back at it and laugh six months from now, but for today I'm feeling pretty good about things.
Update 04/07/2007 - Apparently there are a few more issues with formatting than I thought. A number of their tables are not coming back over correctly, either. We will have to rethink this one a bit...
As I mentioned a couple days ago, I am working on a solution to a problem at work involving Google indexing of Domino web pages with collapsed sections. The consensus was that DXL was the way to go, so I started my foray into uncharted (for me!) territory. By the time the day was done, I had an agent that exports selected documents to an output file, creates a modified file with updated expand/collapse section settings, and then imports that modified file back into the database. I had to piece it along as I went, working slowly but surely through each small chunk of processing logic. The only problem I've seen so far is with sections that start with bullets. It seems like the import routine sticks a empty bullet point at the start of the list. Don't know why, but it does...
Anyway, special thanks go to Mr. DXL, Mac Guidera, who provided me with some email direction and encouragement. I was feeling a bit guilty for not trying to use the NotesXSLTransformer class to do it all without file input/output. But I'm having a really hard time wrapping my mind around XSLT. Mac said that for what I was doing, XSLT was overkill. So I feel better about my approach now. :) Plus, I figure this way I have a before and after file snapshot of what happened. Any spin to help me sleep at night...
Anyway, if you want to see what I did and make fun of my code, check out the Read More... I'm sure I'll look back at it and laugh six months from now, but for today I'm feeling pretty good about things.
Update 04/07/2007 - Apparently there are a few more issues with formatting than I thought. A number of their tables are not coming back over correctly, either. We will have to rethink this one a bit...



Comments
Posted by Duffbert At 17:54:10 On 17/04/2007 | - Website - |
Posted by Ben Langhinrichs At 07:03:59 On 05/04/2007 | - Website - |
Posted by Tom At 20:12:05 On 05/04/2007 | - Website - |
@2... Funny, but as I was posting this I honestly thought "I wonder what Ben would say about this code..."
Your points are well-taken, and if this were more than a one-time conversion agent, I would definitely implement them. But the import works fine regardless of whether anything changed or not. I could change the code to try and build up the entire XML document representation and see if a section occurred, but the payback of time to results would be minimal. And the expand/collapse comment is valid. In this case, I was looking for an explicit 'collapse' (*with* the single quotes included). In our documents, the chances of them using that word with single quotes is non-existent.
If I were going to be having them run this on a regular basis, your changes would be beta v1.1.
Posted by Duffbert At 18:34:26 On 05/04/2007 | - Website - |
To start I highly recommend http://www.w3schools.com/xsl/default.asp
Posted by Mac Guidera At 17:19:20 On 17/04/2007 | - Website - |
I had exactly the same issue with XSLT, I would just avoid it because it didn't make sense to me until I had no choice but to learn it when supporting an application I inherited. It's one of those things which suddenly just clicks and then it all becomes clear. It's worth sticking with if you have the time as you can do some really cool stuff with it.
Matt
Posted by Matt White At 00:43:01 On 05/04/2007 | - Website - |