Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro, Module, function, sub and This workbook and sheets ?
Hi,
For the last couple of days I have been indiscriminately pinching codes from NG and pasting it in to This workbook or by inserting new modules without understanding which should be used for what. I am a newbie and want to learn VBA with excel. Couple of questions based on this:- 1. What is the difference between Sub, Function, Module and code. 2. If I get a code ( from NG) where should I add it . Should I add it "This workbook" or a new module. If possible please tell me in what circumstances one should be adding the code in which of the above 2 3. What is the difference between Public, private with reference to both sub and function. 4. When do we add codes to "Sheet1" rather than workbook. 5. Based on info from newsgroups I learned that a Macro/Module ( I believe macro is recorded and module is anything which is written, please correct me if am wrong) could be called. Can we call both a macro and function from another function/macro 6. Can a module in sheet call a module in another shet/workbook or from module 1. Please guide me to the right source for learing these bsic concepts if possible. Regards, Hari India |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macro to Copy Sheets to new workbook | Excel Discussion (Misc queries) | |||
Need macro to consolidate all sheets in workbook | Excel Discussion (Misc queries) | |||
Macro to create new workbook and sheets | Excel Discussion (Misc queries) | |||
VBA Code To have a macro repeat on all sheets in a workbook | Excel Worksheet Functions | |||
How to automate a macro to run on all sheets in a workbook | Excel Programming |