Good morning iainiow
Excel provides quite a robust framework for writing direct to .txt files, using the Write# and Print# commands. Using Write# will put each value inside a set of quotes, which is undesirable, so we'll use the Print# command instead.
Print# writes a series of values seperated by a tab value. If you don't use a semicolon as I have done in line 9 of the code below then a carriage return (linefeed) character is inserted after each value.
To use this code, highlight the range you want exporting and run the macro. The file that is generated is hardcoded into line 2 - adjust this to suit.
HTH
DominicB
Bookmarks