Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

transfertext won't export to file extension .DAT

Status
Not open for further replies.

cmmsi

MIS
Feb 28, 2003
46
US
Ok folks, in your spare time, perhaps you will give this a look. In using Access 2003, and running a macro to transfer text from a query, it appears that the file extension needs to be .TXT, and perhaps there are a few others.

I use different extensions depending on where the data is going, and what it will do, so I am trying to export in this case to .DAT and I get an error indicating

'Cannot update. Database or object is read only'.

I have checked several places, but to no avail. For reference, here are a couple:


To say I am completely at a loss, is an understatement.

Any ideas?
 
cmmsi,
how about exporting your data to .txt then using vba to change the file extension?
regards,
longhair
 
Tip (VBA code):
Name "filename.txt" As "filename.dat"

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
This can be fixed by a simple registry hack to
HKEy_Local_Machine\Software\Microsoft\Jet\4.0\Engines\Text\Extensions and to
HKEy_Local_Machine\Software\Microsoft\Jet\4.0\Engines\Text\DisabledExtensions

Edit each key and add 'dat' to the list of values already present.

The value 4.0 may be different on your machine depending on which veriosn of Access/Jet is installed.
 
Most excellent, and thank you all. I utilized the registery hack, rebooted, and all is well.

Thanks again.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top