The virtual printer -- Microsoft Office Document Image Writer

You'll see a virtual printer named "Microsoft Office Document Image Writer" is added to your printers' list if you install Office 2003. Use this printer you may get a MDI file.

There are few articles over this function. But I found a good scenario, which this printer does the work perfectly.

(1) First use this printer to print files, like Word, Excel, PowerPoint, NotePad, web pages in browsers, emails in Outlook, pictures in Photoshop .... Yes, you convert files in different formats to a common format -- MDI format.

(2) Office 2003 also provides us a programming interface. We can get the texts in the MDI file via our codes. (only a few lines of codes, quite easily.) And then, you may use an indexing engine, like SQL Server's full-text search ability or NLucene, to create the indexes of the MDI files.

(3) An ActiveX control for viewing MDI files is also contained in Office 2003. You can drop this control onto your Windows Forms, and display a MDI file's content in the control.

Now, you convert the various formats' files to a single format for storing, and create indexes for these files. You may let your user query over the indexes (of cource, it may be full-text searching.), and display the match files in the ActiveX control mentioned above.

A simple "Document Management System" is created till here.


Maybe you have Adobe Acrobat family software (here EXCLUDE the Adobe Acrobat Reader), you also have a virtual printer, which will print out PDF format files. Yes, you may do the same thing just like the MDI solution does.

However, many customers may have Office 2003, or maybe it's in their future plan. The PDF solution need your customer purchase Acrobat's licences. That'll be another big budget.

(The original Chinese version is here.)

posted on 2004-11-10 10:40  破宝  阅读(307)  评论(0编辑  收藏  举报

导航