Group:  Microsoft Access ยป microsoft.public.access.macros
Thread: output to excel in specific sheet

DotNetBag
.NET Development Newsgroups

HTVi
TV Discussion Newsgroups

Our Hot Pick: Rising Antivirus 2006 - Certified by TUV & Checkmark! Get 10% discount by entering this coupon code: ONDISCOUNT10
Rising Antivirus 2006

output to excel in specific sheet
taps54 12.09.2006 19:34:03
Can anyone tell me if there is a way to output a query to an excel file in a
specific sheet from the macro page.

I have the query going to C:\directory\file.xls but this creates a new
workbook and I need to overwrite a specific sheet. Wht is the format for
this.

Thanks
Re: output to excel in specific sheet
"nanne visser" <nvisser2[ at ]home.nl> 15.09.2006 13:11:27
use macro output to.....


"taps54" <taps54[ at ]discussions.microsoft.com> schreef in bericht
news:DB940CC9-D5B0-447F-AB18-189D0206B096[ at ]microsoft.com...
[Quoted Text]
> Can anyone tell me if there is a way to output a query to an excel file in
> a
> specific sheet from the macro page.
>
> I have the query going to C:\directory\file.xls but this creates a new
> workbook and I need to overwrite a specific sheet. Wht is the format for
> this.
>
> Thanks


Re: output to excel in specific sheet
ashfire 20.09.2006 14:25:02
output to simply overwrites the file, he's asking if you can overwrite a
single sheet

"nanne visser" wrote:

[Quoted Text]
> use macro output to.....
>
>
> "taps54" <taps54[ at ]discussions.microsoft.com> schreef in bericht
> news:DB940CC9-D5B0-447F-AB18-189D0206B096[ at ]microsoft.com...
> > Can anyone tell me if there is a way to output a query to an excel file in
> > a
> > specific sheet from the macro page.
> >
> > I have the query going to C:\directory\file.xls but this creates a new
> > workbook and I need to overwrite a specific sheet. Wht is the format for
> > this.
> >
> > Thanks
>
>
>
Re: output to excel in specific sheet
"Ron2006" <ronnemec[ at ]hotmail.com> 21.09.2006 19:58:26
The tab that the Access export process uses is the same as the query or
table name that is used to do the export.

I used to be able to repeat exports and have them overwrite that tab,
now it seems to creat a second tab with almost identical name. (If
someone knows the magic clue to stop that I would love to know it.)

Now what I do is first use automation and open the spreadsheet via
Access and make it visible and have the user say yes to the delete of
that tab. Then I do the export.

If the tab needs formatting and I can do that from within Access I then
use automation to do just that.

If the formatting is too extensive then I export it to a different tab
name and then use automation to copy the necessary data from that raw
export tab to the highly formatted tab. If I can't leave the rawexport
tab then I either hide it or make excel visible and have the user say
yes to the delete.

Ron

Home | Search | Terms | Imprint | Contact
Newsgroups Reader - provided by WiredBox.Net