Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Once you have a reference to the CodeModule, you read lines with the Lines method: S=CodeMod.Lines(100,10) This puts in S text starting at line 100 for 10 lines. You also use methods line InsertLine, DeleteLine, and ReplaceLine to modify the code. See www.cpearson.com/Excel/VBE.aspx for lots of information and example cdoe for working with the VBA Editor objects. Cordially, Chip Pearson Microsoft MVP 1998 - 2010 Pearson Software Consulting, LLC www.cpearson.com [email on web site] On Thu, 7 Jan 2010 07:32:18 -0800 (PST), Phil Hibbs wrote: Is there a way of accessing the code in a module in a spreadsheet? I can get as far as the VBComponent.CodeModule but can't work out how to access the actual code. Phil Hibbs. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Accurately reading the contents of another spreadsheet | Excel Programming | |||
Problem reading value from Excel spreadsheet | Excel Programming | |||
reading data from com port into excel spreadsheet | Excel Programming | |||
Reading from a .xls spreadsheet based on a cell name | Excel Programming | |||
reading cells from a spreadsheet using VB | Excel Programming |