Home All Groups Group Topic Archive Search About
Author
22 Feb 2006 2:57 PM
Robin Walter
Hello,

i must read all Text from a word document with VB.net and save them in a
string variable, but i don´t know how :-( ?
Can anybody help me ?

Thanks
Robin

Author
22 Feb 2006 8:56 PM
iwdu15
try this

dim strFile as string
Dim fs as new IO.Filestream("C:\myworddoc.doc", FileMode.Read,
FileAccess.Read)
Dim sr as new IO.StreamReader(fs)

strfile = sr.ReadToEnd


--
-iwdu15
Author
23 Feb 2006 6:58 AM
Robin Walter
Hello,

thanks but now i have the binary String from the Worddokument. I need all
word´s without pictures etc.

Thanks
Robin

Show quoteHide quote
"iwdu15" <jmmgoalsteratyahoodotcom> schrieb im Newsbeitrag
news:C8843D2D-3424-4F55-B24D-CE2D919E7389@microsoft.com...
>
> try this
>
> dim strFile as string
> Dim fs as new IO.Filestream("C:\myworddoc.doc", FileMode.Read,
> FileAccess.Read)
> Dim sr as new IO.StreamReader(fs)
>
> strfile = sr.ReadToEnd
>
>
> --
> -iwdu15