Export to text file, and VBA

M

maya

Hi,
I would like to know how to perform the following:

1) I need to export from an mdb to a text file format. i
use the transfer text method. it works great, the problem
is, i need to assign a different extention to the file,
other the TXT. when i do that, it gives me an error
message saying the db is read only. can this be solved?

2) when i do this export, how can i define using vba:
2.1) create a folder if it does not exist to save the
file in it
2.2) open the folder to view it's content when an event
happens
?

thanks in advance
 
A

Allen Browne

TransferText used to be intelligent enough to work with any file extension,
but was crippled about 5 years back so it now only works with registered
file types. The simplest workaround is probably to export the file and then
rename it with the Name statement.

MkDir can make a folder.

FollowHyperlink opens the Windows Explorer if used with a folder name.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Lock VBA 9
schema to text file 7
Word to Excel: Export comments with text and line number 0
Export to TXT file 4
Tab delimited export doesn't work 2
Export to Excel 3
VBA - Export Tables 3
export to text file 8

Top