You are hereBlogs / rahul's blog / Token Replacement in Office documents

Token Replacement in Office documents


rahul's picture

By rahul - Posted on 11 October 2009

A common situation is to prepare invoices, etc. from information in a database. Clients usually have extremely customized invoice formats, but the data to be filled in is basically the same. This article and its related code present a new (I have searched, but could not find anything related to this topic, so I believe it's new), innovative, and productive way of producing dynamic Office documents. I am using the word Office in this entire document as it does not relate solely to Microsoft Office. I have tested this approach on Open Office as well, and it works. The associated code enables to perform Token Replacement on both Office products.

Again, due to a larger community available at CodeProject, this article together with its Source Code is available if full at:

http://www.codeproject.com/KB/office/OfficeTokenReplacement.aspx

The Code for the article is also attached below.

UPDATE:

  •  (Feb 24, 2010) - Fixed a minor bug in replacement of header/footer sections.
AttachmentSize
OfficeTokenReplacement - with Add-Ins.zip703.71 KB
OfficeTokenReplacement - without Add-Ins.zip613.87 KB

Excellent article, i just want to thank you for good read..

Your blog is full of interesting articles, thanks for good read

Very interesting blog, bookmarked for the future referrence, what template do you use ?

rahul's picture

Hi, which template are you talking about??

Hey, I found your blog while searching on Google your post looks very interesting for me. I will add a backlink and bookmark your site. Keep up the good work!

I often read your blog, i think you are good writer, keep us posting

You have to express more your opinion to attract more readers, because just a video or plain text without any personal approach is not that valuable. But it is just form my point of view

Your blog keeps getting better and better! Your older articles are not as good as newer ones you have a lot more creativity and originality now. Keep it up! And according to this article, I totally agree with your opinion, but only this time! :)

Post new comment

The content of this field is kept private and will not be shown publicly.

Mollom CAPTCHA (play audio CAPTCHA)
Type the characters you see in the picture above; if you can't read them, submit the form and a new image will be generated. Not case sensitive.