Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / January 2005

Tip: Looking for answers? Try searching our database.

Import a DOS-file to word

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Per - 16 Jan 2005 13:41 GMT
I want to import a DOS-file into Word 2000 with norwegian characters using
VBA Documents.Open.

Can anyone tell how.
Jezebel - 16 Jan 2005 22:24 GMT
Dim pDoc as Word.Document
Set pDoc = Documents.Open(FileName:="C:\.......txt",
Format:=wdOpenFormatText)

If that doesn't work with your file format, use

Set pDoc = Documents.Open(FileName:="C:\.......txt", _
Format:=FileConverters("[Format]").OpenFormat)

Where [Format] is whatever you select in the 'Files of type' list to open
your file if you're doing it manually.

> I want to import a DOS-file into Word 2000 with norwegian characters using
> VBA Documents.Open.
>
> Can anyone tell how.
Per - 21 Jan 2005 17:15 GMT
Thank you for answering.

When I use:
Set pDoc = Documents.Open(FileName:="C:\.......txt",_
Format:=wdOpenFormatText)
the text is imported without our national characters.

When I use:
Set pDoc = Documents.Open(FileName:="C:\.......txt", _
Format:=FileConverters("[Format]").OpenFormat)
Format = "MS-DOS text with Layout"
I get this error: Kommandoen mislyktes (Failure)

This is maybe a special norwegian problem?

Jezebel skrev:

> Dim pDoc as Word.Document
> Set pDoc = Documents.Open(FileName:="C:\.......txt",
[quoted text clipped - 12 lines]
> >
> > Can anyone tell how.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.