Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run Macro with Excel Object ( from MS. Visual FoxPro 7.0 )
Hi,
I have a routine, that creates a Workbook, and a lot of tables to make Graphs, but make graph with automation it's very afull, so i create a macro, and i have de Macro.bas ( module ). I want to link this macro to every workbook created with the routine, and launch (macro), but I'dont know how to link or bind the macro to the new workbook , and after that , launch. Regards, and good day Helpme !!!!!! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run Macro with Excel Object ( from MS. Visual FoxPro 7.0 )
Hi Programmer,
You can add a macro to an Excel workbook with automation using oExcel.ActiveWorkbook.VBProject.VBComponents("This Workbook").CodeModule.AddFromFile("C:\MacroCode.tx t") You can run your macro using oExcel.Application.Run("MyMacro") -- Cindy Winegarden MCSD, Microsoft Visual Foxpro MVP www.cindywinegarden.com Blog: http://spaces.msn.com/members/cindywinegarden "Visual FoxPro programmer" m wrote in message ... Hi, I have a routine, that creates a Workbook, and a lot of tables to make Graphs, but make graph with automation it's very afull, so i create a macro, and i have de Macro.bas ( module ). I want to link this macro to every workbook created with the routine, and launch (macro), but I'dont know how to link or bind the macro to the new workbook , and after that , launch. Regards, and good day Helpme !!!!!! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Add Visual Foxpro 9 DBF import / Export to Excel 2007 | Excel Worksheet Functions | |||
REFERENCING WORKSHEET CELL FROM VISUAL FOXPRO FORM | Excel Discussion (Misc queries) | |||
Require draggable visual object in Excel VBA | Excel Programming | |||
Excel 2003 Database Driver Visual FoxPro 7 on Server 2003. | Excel Discussion (Misc queries) | |||
Creating a spreadsheet from Foxpro using Object Model | Excel Programming |