+ Reply to Thread
Results 1 to 4 of 4

Call Code in One Module Into Another

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    05-20-2008
    Location
    Virginia
    MS-Off Ver
    2003
    Posts
    129

    Call Code in One Module Into Another

    Hi All,

    Could anyone give me a simple example of how you call code from one module into another. I would like to try making different modules containing different code. Then some how use the code from one module in another one. thanks - SEOT

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259
    Hello SEOT,

    It isn't very clear from your post what you want to do. When you say "module", do you mean a Sub or Function or are you referring to a VBA Module? Are the modules in the same workbook or in different workbooks?

    Sincerely,
    Leith Ross

  3. #3
    Forum Contributor
    Join Date
    05-20-2008
    Location
    Virginia
    MS-Off Ver
    2003
    Posts
    129

    Leith Ross- I believe Sub

    I have been putting all my code in these things called modules on the visual basic editor, but the start with Private Sub and end with End Sub on each of these. Do you have a simple example of calling code between these things. I hope you understand what I am trying to say here. I have been trying to read a little on how this all works, but I have not figured it all out yet. thank you-- SEOT

  4. #4
    Forum Contributor
    Join Date
    05-20-2008
    Location
    Virginia
    MS-Off Ver
    2003
    Posts
    129

    Leith Ross- I found it!!!

    I figured it out after playing with it for about an hour now. I use a call procedure and drop the code in a module. Then, I can use the code in the module in other places within the workbook. I appreciate you trying to help me my friend- SEOT

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Placement of a particular line of code
    By smurray444 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-19-2007, 11:15 AM
  2. Excel closes when using VBA to write VBA code
    By btoback in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-04-2007, 03:42 PM
  3. Selectable list box
    By mkmed in forum Excel Programming / VBA / Macros
    Replies: 22
    Last Post: 05-29-2007, 02:41 PM
  4. Finding next empty row in another worksheet
    By spyrule in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-13-2006, 10:56 AM

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