473,406 Members | 2,439 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Exporting a table to a Tab delimeted Text File via code

I am trying to use the DoCmd.TransferText method to export an access table
to
a Tab Delimited Text File. I have put the code behind the onclick event of
a button
and keep getting the error "Run-time error '32027': Cannot update. Database
or object is read-only"

Code I using is:

Private Sub ExportButton_Click()
DoCmd.TransferText acExportDelim, , "TableName", "c:\export.txt"
End Sub

Am I missing something?
Nov 13 '05 #1
1 3936
Your code works fine in exporting a text file with comma and double quote
delimiters. Try checking your table for field values containing commas or
double quotes. Check to see if the text file you are writing already exists
and is read-only. You might try prefacing your docmd line with one that
checks for the text file and deletes it, before executing the export
operation.
nunYa<nu***@yourmomma.com> Friday, March 18, 2005 >>>

I am trying to use the DoCmd.TransferText method to export an access table
to
a Tab Delimited Text File. I have put the code behind the onclick event of
a button
and keep getting the error "Run-time error '32027': Cannot update. Database
or object is read-only"

Code I using is:

Private Sub ExportButton_Click()
DoCmd.TransferText acExportDelim, , "TableName", "c:\export.txt"
End Sub

Am I missing something?


Nov 13 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Fran Zablocki | last post by:
I have a process that exports an Access table to a comma-delimited text file. One of the fields that is exported shows the date it was exported, using the Date() function. In the Access table, the...
2
by: Kenneth | last post by:
How do I remove the limitation in Access that deny me from exporting 24000 rows and 17 columns (in a query) into Excel? Kenneth
4
by: russ | last post by:
Hi I am in the unfortunate position of having to use some code someone has programmed in access and i have to get the data out. i am picking a table to export and exporting it as a text file. ...
6
by: Kevin Chambers | last post by:
Hi all-- In an attempt to commit an Access MDB to a versioning system (subversion), I'm trying to figure out how to convert a jet table's metadata to text, a la SaveAsText. The end goal is to...
2
by: Snozz | last post by:
The short of it: If you needed to import a CSV file of a certain structure on a regular basis(say 32 csv files, each to one a table in 32 databases), what would be your first instinct on how to...
6
by: sara | last post by:
I have what I think is a little strange...I have to get data from our payroll system into a specific format (fixed record length) as a .txt or .prn file only to upload to our 401k custodian. I...
16
by: pmatzek | last post by:
I am attempting to automate a process involving importing a .txt file into an existing table, changing a date in each record, then exporting the table, again as a .txt file. One field contains a...
17
by: Stubert | last post by:
I have a training module db that stores information about employees and what training they have carried our or need to carry out. One table in this database stores what training needs to be carried...
1
by: Marty Klunk | last post by:
I have an Access97 data base where we are exporting records out to a text file that is then sent to a customer via EDI transmission. The problem I am having is that during the export process access...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.