Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
I have a macro in excel, and I would like to add a sub that would - open Access - Copy the results of a query into a new spreadsheet of my workbook - close Access Thanks lylo |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Have you tried just using the Data / Import External data option which will
allow you to query Access? Recording the macro will give you the syntax, you can query as you would in Access and you won't even need to open Access, and you can then choose to return the results to a sheet in your Excel workbook. -- Regards Ken....................... Microsoft MVP - Excel Sys Spec - Win XP Pro / XL 97/00/02/03 ---------------------------------------------------------------------------- It's easier to beg forgiveness than ask permission :-) ---------------------------------------------------------------------------- "lylo" wrote in message om... Hi, I have a macro in excel, and I would like to add a sub that would - open Access - Copy the results of a query into a new spreadsheet of my workbook - close Access Thanks lylo --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.726 / Virus Database: 481 - Release Date: 22/07/2004 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi !
Yes, it's working thanks a lot. I don't even need to write a macro as the table would refresh each time the worksheet is opened ! Cheers lylo "Ken Wright" wrote in message ... Have you tried just using the Data / Import External data option which will allow you to query Access? Recording the macro will give you the syntax, you can query as you would in Access and you won't even need to open Access, and you can then choose to return the results to a sheet in your Excel workbook. -- Regards Ken....................... Microsoft MVP - Excel Sys Spec - Win XP Pro / XL 97/00/02/03 ---------------------------------------------------------------------------- It's easier to beg forgiveness than ask permission :-) ---------------------------------------------------------------------------- "lylo" wrote in message om... Hi, I have a macro in excel, and I would like to add a sub that would - open Access - Copy the results of a query into a new spreadsheet of my workbook - close Access Thanks lylo --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.726 / Virus Database: 481 - Release Date: 22/07/2004 |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You're welcome :-)
-- Regards Ken....................... Microsoft MVP - Excel Sys Spec - Win XP Pro / XL 97/00/02/03 ---------------------------------------------------------------------------- It's easier to beg forgiveness than ask permission :-) ---------------------------------------------------------------------------- <snip --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.727 / Virus Database: 482 - Release Date: 26/07/2004 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
No Results returned from Access query | Excel Discussion (Misc queries) | |||
Remove Access query name title from Excel spreadsheet | Excel Discussion (Misc queries) | |||
Access macros in Excel - populate results in spreadsheet | Excel Discussion (Misc queries) | |||
Why are access query results different in Excel | Excel Discussion (Misc queries) | |||
Access query results to Excel | Excel Discussion (Misc queries) |