Solved

Reading MS Word line by line to save as Tiff Image using C#.Net

Posted on 2007-03-26
3
292 Views
Last Modified: 2013-12-17
Hi All
I have special requirment. In this, I need to read Ms Word document line by line with the all the Font and display settings. That's i have to know how many characters in an line and all the things. For e.g
If i'm reading an document and saving into an tiff image. The line's are getting collapsed soem time and the fonts are goes out of the control. If any body have any suggestion on this. Please help me out
0
Comment
Question by:santhimurthyd
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 

Accepted Solution

by:
jdaragon earned 250 total points
ID: 18792317
Alas, the short answer is that you cannot do this.  

Word (like most modern word processors) doesn't really embody the concept of a line of text (except in special cases like a header...). Text flows within a paragraph depending on several factors : font size, the actual characters, and the physical characteristics (page size, margin settings, etc.) of the printer device context selected.

Most (if not all) software that renders Word to TIFF does it by implementing a printer driver based on the raster printer model. This means that Word (or whatever other Windows program is generating print) is responsible for rendering the text into the DC, and the driver is called for each line of pixels that is produced.  It's pretty easy to take each line of pixels, pass them into your compression routines, and generate a TIFF file without knowing *anything* about Word file structures, font metrics or anything else.

0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It seems a simple enough task, yet I see repeated questions asking how to do it: how to pass data between two forms. In this article, I will show you the different mechanisms available for you to do just that. This article is directed towards the .N…
This article describes relatively difficult and non-obvious issues that are likely to arise when creating COM class in Visual Studio and deploying it by professional MSI-authoring tools. It is assumed that the reader is already familiar with the cla…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…

617 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question