Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA Code - Excel & Access
I am trying to create a code in an Excel workbook that when I run the macro
it will perform the following functions in the following sequence. 1. Open an Access Database called Asset 2. Copy each record (126 total) from the table called Product Information 3. Create a new worksheet for each record and paste the contents in cells B2:B11 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA Code - Excel & Access
hi
see this site. you may have to modify some. http://www.vbaexpress.com/kb/getarticle.php?kb_id=889 regards FSt1 "Workbook" wrote: I am trying to create a code in an Excel workbook that when I run the macro it will perform the following functions in the following sequence. 1. Open an Access Database called Asset 2. Copy each record (126 total) from the table called Product Information 3. Create a new worksheet for each record and paste the contents in cells B2:B11 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA Code - Excel & Access
What I rec ommmend is to get everything from acess and put the data into one
worksheet and then split the sheet into 126 new worksheets. To get the data from Access I would record a macro while doing the operation manually. Then modify the recorded Macro as required. 1) To Record Macro from worksheet menu - Tools - Macro - Record new Macro 2) Get data from Access use worksheet menu - Data - Import External Data - New Data Base Query - MS Access database - Press Ok. Then select file and Press OK. Select options as required. After you get the code you can post the code so it can be modified. Each record should be one row on the spreadsheet so it will be easy to create a new worksheet for each row. The macro can be written to format and move the data as required. "Workbook" wrote: I am trying to create a code in an Excel workbook that when I run the macro it will perform the following functions in the following sequence. 1. Open an Access Database called Asset 2. Copy each record (126 total) from the table called Product Information 3. Create a new worksheet for each record and paste the contents in cells B2:B11 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Run Excel VBA code inside Access | Excel Discussion (Misc queries) | |||
Excel code convert to Access code - Concat & eliminate duplicates | Excel Programming | |||
Hyperlink in access from excel code | Excel Programming | |||
Using Access in Excel VB Code | Excel Discussion (Misc queries) | |||
Is there somewhere I can access Excel-VB code at once? | Excel Programming |