473,659 Members | 3,420 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Export a table but increment the name

31 New Member
I posted a question simalar to this before but was not clear on what I was trying to do. I am using two tables one primary and a temp table. I import my data to the temp table and bounce it against the primary table and append the primary table with the new data for export. The problem is I have set a command button to do this and if the user selects the button twice the name of the output.txt file is then zero. I need to add an increment number or letter to the output name. Is this possible. I have tried the date but that still will not work if I export 2 or more files the same day.
Thanks,
Wayne L
Nov 8 '07 #1
3 1427
Rabbit
12,516 Recognized Expert Moderator MVP
What about using Date and Time down to the second?
Nov 8 '07 #2
Wayne L
31 New Member
Here is what worked for me.


Expand|Select|Wrap|Line Numbers
  1. Private Sub Export_text_Date_Click()
  2. 'TheDate = Month(Date) & "-" & Day(Date) & "-" & year(Date)
  3. TheDate = (Format(Now(), "yymmdd-hhmmss AM/PM")) & ".txt"
  4. TheFile = ("C:\FSMFILES\A4A\A4A ") & TheDate & ""
  5. DoCmd.TransferText acExportFixed, "Import/Export SPECS", "YourTbl",(TheFile), False
  6. End Sub
  7.  
Wayne L
Nov 9 '07 #3
Rabbit
12,516 Recognized Expert Moderator MVP
Glad you got it working.
Nov 9 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

2
3356
by: jaks | last post by:
How can I export a MySQL table with a different name using phpmyadmin? I want to export nuke_bbsearch_wordmatch and all it contents to phpbb_search_wordmatch This table in a different db. Fields are the same just the name needs to be changed. When exporting. I have been editting the rest of the table I need manually bt editting them in notepad but the table 4 columns and has 170,000 entries.
4
21475
by: Paolo | last post by:
Hello, I am trying to create a procedure to export my Access data to a word template. I would like to export data from two tables to a word file at the same time. My two tables are named CASES AND CLIENTS. The word (it is a template) is named MASTER To store data, I have created two forms named CASES and MASTER. Since both forms have a lot of fields, I have added the form CLIENTS as a SubForm on the form CASES.
1
2685
by: Ted Theodoropoulos | last post by:
i posted an earlier thread about exporting data from a subform in an ..ADP to an .MDB file. i had only one gracious response but it wouldn't work in the given situation. so i thought i would share the code with you that i wrote to solve the problem. certainly nothing sophisticated but it would have been very helpful to me had i gotten ahold of it when i started out to tackle the problem. i welcome any feedback. the solution uses a...
0
8428
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8337
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8748
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
6181
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5650
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4335
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2754
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1978
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1739
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.