473,794 Members | 2,748 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

acces 97: export multiple queries into one workbook

is it possible to export multiple queries into one workbook, having
each query as separate worksheet? i cannot specify a range because the
records will change on a daily basis as for query size.
i tried the following transferspreads heet method but the database
could not find 'TFM$' because it was not a valid parameter.

DoCmd.TransferS preadsheet acExport, 8, "TFM",
"C:\Temp\NonCri tical.xls", True, "'TFM'!"
DoCmd.TransferS preadsheet acExport, 8, "STRUCTURED ",
"C:\Temp\NonCri tical.xls", True, "'STRUCTURE D'!"
DoCmd.TransferS preadsheet acExport, 8, "NRT",
"C:\Temp\NonCri tical.xls", True, "'NRT'!"

thanks in advance
jung
Nov 12 '05 #1
2 2540
I'm also doing this in one of my Access project.

Maybe you can just omit the last parameter from your codes, i.e., "TFM'!'",
"'STRUCTURED'!' ", "'NRT'!". I don't think these are necessary. The
worksheets will have names the same as the queries that are being exported.

Herbert

"JMCN" <pi******@yahoo .fr> ¦b¶l¥ó
news:27******** *************** **@posting.goog le.com ¤¤¼¶¼g...
is it possible to export multiple queries into one workbook, having
each query as separate worksheet? i cannot specify a range because the
records will change on a daily basis as for query size.
i tried the following transferspreads heet method but the database
could not find 'TFM$' because it was not a valid parameter.

DoCmd.TransferS preadsheet acExport, 8, "TFM",
"C:\Temp\NonCri tical.xls", True, "'TFM'!"
DoCmd.TransferS preadsheet acExport, 8, "STRUCTURED ",
"C:\Temp\NonCri tical.xls", True, "'STRUCTURE D'!"
DoCmd.TransferS preadsheet acExport, 8, "NRT",
"C:\Temp\NonCri tical.xls", True, "'NRT'!"

thanks in advance
jung

Nov 12 '05 #2
"Herbert Chan" <he*****@chan.c om> wrote in message news:<40******* ***@rain.i-cable.com>...
I'm also doing this in one of my Access project.

Maybe you can just omit the last parameter from your codes, i.e., "TFM'!'",
"'STRUCTURED'!' ", "'NRT'!". I don't think these are necessary. The
worksheets will have names the same as the queries that are being exported.

Herbert

thanks herber! you are totally correct! for some reason i thought i
needed to indicate the name of the worksheet even if i did not have a
range.
thanks again! cheers - jung
Nov 12 '05 #3

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

Similar topics

0
3271
by: Dayron | last post by:
Hi, I would like export the records retrieved from database to excel worksheets. unfortunately, each worksheet will support until 65535 records and I have about 1 million of records to write. So I have to write into few worksheets in the same workbook. But I cant get the way how to do it. I manage to create the new worksheet in my workbook but I cannot write content into it. How can I do so? Below is the example output source...
0
1529
by: Makuhari1998 | last post by:
Is it possible to create a macro that will open 7 reports at once and automatically export the results of each report into Excel? Can the results be exported into the same Excel workbook, or will they be in 7 different workbooks? Can I create a button on the main form of my database to run this macro? Also, is it possible to write a macro that can open several *queries* at once and export them into Excel? If so, will the data labels of...
2
405
by: JMCN | last post by:
is it possible to export multiple queries into one workbook, having each query as separate worksheet? i cannot specify a range because the records will change on a daily basis as for query size. i tried the following transferspreadsheet method but the database could not find 'TFM$' because it was not a valid parameter. DoCmd.TransferSpreadsheet acExport, 8, "TFM", "C:\Temp\NonCritical.xls", True, "'TFM'!" DoCmd.TransferSpreadsheet...
4
3437
by: Anthony Cuttitta Jr. | last post by:
I'm working on some procedures where Access queries are exported to Excel, and then later on, those same workbooks are openned, and I need to target a specific original sheet. Sometimes there will be multiple sheets in the same workbook, sometimes only a single tab. The issue is this: Save query "XLTest - qryExport" to file and the worksheet name becomes "XLTest___qryExport" (three underscores). I have a generic procedure which...
4
8720
by: paul.chae | last post by:
I have a table in Access with about 3000 records. There are ~60 unique values in the ID field for the 3000 records. What I would like to do is automatically generate multiple Excel worksheets within a single workbook with these records. I would end up with around 500 worksheets, 1 for each unique ID value. I was thinking this could be done if I have an exported flag column in the table, and I search for the max (or min) on the ID...
0
2429
by: Tony2299 | last post by:
How to export data using ASP to excel workbook (with multiple worksheets)? I created an excel workbook with 5 worksheets and each one has a name range. Using asp I insert data to individual worksheet. The problem is that excel treat all numbers as string/text when I do: rsExcel.Fields(0).Value = 5 When I open an excel file the value 5 is display as "5" If I use application/vnd.ms-excel method I can get the value display correctly...
7
7810
by: Vanessa | last post by:
hi Everyone, I have two questions on exporting data to Excel using ASP (w/o converting formatted excel file into web page and then plug in the dynamic data): 1. Can we export data into different sheets at Excel? 2. Can we do graph at export? Thanks!!
3
7558
by: jmarcrum | last post by:
I want to export a report (that contains two separate queries, 1. Current year data, and 2. split-year data) from access into excel, but everytime I run my code and export the data to excel, it looks like garbage. I have maximize and minimize buttons on the left side of the excel spreadsheet that I don't want. I want separate tabs on the bottom of the spreadsheet that show the two queries separately from one another. But I don't know how...
10
3898
by: bill | last post by:
I have been searching everywhere AND am a bit new to vb .net/aspx, but can't seem to find anything that works. Specifically, I need to export a dataset from a webapp written in vb .net to a new excel spreadsheet with multiple tabs (each tab would contain different rows from the dataset). Does anyone have any sample code or examples I might look at? tia, Bill
0
9518
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
10433
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10212
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
10161
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10000
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7538
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...
1
4112
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
3720
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2919
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.