+ Reply to Thread
Results 1 to 6 of 6

Where to put Code

  1. #1
    Registered User
    Join Date
    12-12-2006
    Posts
    33

    Smile Where to put Code

    Hi everyone, I have been tinkering now with Excel VBA for about a few weeks now. I have learned quite a lot from you all and I thank you for assisting with my novice questions.

    I have been creating a test project that allows me to use almost everything I have learned so far.

    for me I just jumped in with a idea of what I wanted to build.
    I did not initially plan out the project as it was a test project (I know Poor thought Process)
    As I progressed with the functionality of my project a reoccuring thought has been bothering me which I have looked for information here but really did not find the reasons or answers to the issue.
    My question to you is (and I am sure there are multiple answers based upond design)

    When do you place code (sub functions) in a module versus say in a Userform object ? (object maybe not the correct terminology)
    and Why ?
    This is probably one of the basics I should have asked prior to designing my test project but too late for that... for my next learning project I would like to understand that before beginning.

    Thanks again for all your support and responses.
    RobertCo

  2. #2
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326
    There are lots of places on the web well suited for answering your questions.
    Have a look at them.
    But also use the XL macro recorder and try to understand and modify what has been recorded.
    Combining both approaches will certainly help you on the way.
    BUT don't forget, XL has got a lot of functions and functionalities !
    Don't try reinventing the wheel, much of what you need is already there.

    Good Luck !

  3. #3
    Forum Contributor
    Join Date
    03-13-2005
    Posts
    6,195
    Quote Originally Posted by RobertCo
    Hi everyone, I have been tinkering now with Excel VBA for about a few weeks now. I have learned quite a lot from you all and I thank you for assisting with my novice questions.

    I have been creating a test project that allows me to use almost everything I have learned so far.

    for me I just jumped in with a idea of what I wanted to build.
    I did not initially plan out the project as it was a test project (I know Poor thought Process)
    As I progressed with the functionality of my project a reoccuring thought has been bothering me which I have looked for information here but really did not find the reasons or answers to the issue.
    My question to you is (and I am sure there are multiple answers based upond design)

    When do you place code (sub functions) in a module versus say in a Userform object ? (object maybe not the correct terminology)
    and Why ?
    This is probably one of the basics I should have asked prior to designing my test project but too late for that... for my next learning project I would like to understand that before beginning.

    Thanks again for all your support and responses.
    RobertCo
    Robert,

    try http://www.cpearson.com/excel/codemods.htm

    I think that best explains what you asked.

    hth
    ---
    Si fractum non sit, noli id reficere.

  4. #4
    Registered User
    Join Date
    12-12-2006
    Posts
    33
    Arthur and Bryan Thank you for your replies,

    Bryan that is exactly what I was looking for, I will read up and learn.

    You guys really help a lot thanks again.

  5. #5
    Forum Contributor
    Join Date
    03-13-2005
    Posts
    6,195
    Quote Originally Posted by RobertCo
    Arthur and Bryan Thank you for your replies,

    Bryan that is exactly what I was looking for, I will read up and learn.

    You guys really help a lot thanks again.
    good to see, and thanks for the response
    ---

  6. #6
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326
    Glad to help

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1