Results 1 to 30 of 30

Exporting files to text files

Threaded View

  1. #12
    Registered User
    Join Date
    08-02-2012
    Location
    Dordrecht, Netherlands
    MS-Off Ver
    Excel 2010
    Posts
    31

    Re: Exporting files to text files

    Quote Originally Posted by MrShorty View Post
    From your screenshot, it looks like you are working from different code from what is posted in post #5. I'm using the code given in post #5. Here's the file and the sample output file.
    Mr. Shorty thanks for the help.

    I'm now able to actually export a file to text. In your code you have the browser location for the textfiles.

    FileName = "C:\Erwin\Test\Excel\test1.txt" 'Application.GetSaveAsFilename(InitialFileName:=vbNullString, FileFilter:="Text Files (*.txt),*.txt")
    If FileName = False Then

    So now the file is written to directory C:\Erwin\Test\Excel\ and than the filename. Is it possible to use the name (test1.txt) from cell R3C21?
    Is it possible to save the file in the same folder as the excelfile itself? So if i copy the excel to my other notebook with a different directory it doesn't gives an error?

    And the textfile is the same as yours. The upcoming problem now is that i don't want the "" signs in the file otherwise the program can't read the textfile. A space must be a space (see attachment for an idea of the required textfile.)

    Also the textfile is quite long, I always want to expert cell range R3C6 to R104C6, is this achievable?

    Thanks again for your help
    Attached Files Attached Files

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1