write a table to a file

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I am using StreamWriter to write text files now. What is the easiest way to
write a word table to a file? XML + style?

Thanks. -Dale
 
Dale,

What do you mean write a word table to a file? You could always use an
XmlTextWriter instance (passing in your StreamWriter) and write XML with
that. Or did you mean something else?

Hope this helps.
 
Nicholas,

Thank you for your support. When I write a MS word table to a text file, I
lost all frames (like lines). I just want to keep all words and lines.

-Dale

Nicholas Paldino said:
Dale,

What do you mean write a word table to a file? You could always use an
XmlTextWriter instance (passing in your StreamWriter) and write XML with
that. Or did you mean something else?

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

dale zhang said:
Hi,

I am using StreamWriter to write text files now. What is the easiest way
to
write a word table to a file? XML + style?

Thanks. -Dale
 
Dale,

Text files don't support the formatting that word documents support.
How do you expect to see the lines and whatnot?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

dale zhang said:
Nicholas,

Thank you for your support. When I write a MS word table to a text file, I
lost all frames (like lines). I just want to keep all words and lines.

-Dale

Nicholas Paldino said:
Dale,

What do you mean write a word table to a file? You could always use
an
XmlTextWriter instance (passing in your StreamWriter) and write XML with
that. Or did you mean something else?

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

dale zhang said:
Hi,

I am using StreamWriter to write text files now. What is the easiest
way
to
write a word table to a file? XML + style?

Thanks. -Dale
 
Nicholas,

That is why I am asking if xml can serve the need?

THanks. -dale

Nicholas Paldino said:
Dale,

Text files don't support the formatting that word documents support.
How do you expect to see the lines and whatnot?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

dale zhang said:
Nicholas,

Thank you for your support. When I write a MS word table to a text file, I
lost all frames (like lines). I just want to keep all words and lines.

-Dale

Nicholas Paldino said:
Dale,

What do you mean write a word table to a file? You could always use
an
XmlTextWriter instance (passing in your StreamWriter) and write XML with
that. Or did you mean something else?

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

Hi,

I am using StreamWriter to write text files now. What is the easiest
way
to
write a word table to a file? XML + style?

Thanks. -Dale
 
Dale,

XML is a data representation, it isn't a formatted document. Or are you
trying to save the word document in XML format? If so, you will have to
call the Save method on the Document class in Word (when you automate it)
and tell it to output XML when saving (assuming you are working with the
version of word that supports persisting to XML as well).


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

dale zhang said:
Nicholas,

That is why I am asking if xml can serve the need?

THanks. -dale

Nicholas Paldino said:
Dale,

Text files don't support the formatting that word documents support.
How do you expect to see the lines and whatnot?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

dale zhang said:
Nicholas,

Thank you for your support. When I write a MS word table to a text
file, I
lost all frames (like lines). I just want to keep all words and lines.

-Dale

:

Dale,

What do you mean write a word table to a file? You could always
use
an
XmlTextWriter instance (passing in your StreamWriter) and write XML
with
that. Or did you mean something else?

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

Hi,

I am using StreamWriter to write text files now. What is the easiest
way
to
write a word table to a file? XML + style?

Thanks. -Dale
 
Hi,

XML is not useful at all in your situation (if I understand it correctly)
I'm afraid you will haveto format the table yourself.

In anyway converting a MS-Word file to a text file is a big problem if you
want to keep all the feature word allow you.

What r u goig to do with the images?
OR the header and/or footer?


cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation


dale zhang said:
Nicholas,

That is why I am asking if xml can serve the need?

THanks. -dale

Nicholas Paldino said:
Dale,

Text files don't support the formatting that word documents support.
How do you expect to see the lines and whatnot?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

dale zhang said:
Nicholas,

Thank you for your support. When I write a MS word table to a text
file, I
lost all frames (like lines). I just want to keep all words and lines.

-Dale

:

Dale,

What do you mean write a word table to a file? You could always
use
an
XmlTextWriter instance (passing in your StreamWriter) and write XML
with
that. Or did you mean something else?

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

Hi,

I am using StreamWriter to write text files now. What is the easiest
way
to
write a word table to a file? XML + style?

Thanks. -Dale
 
Back
Top