![]() |
Using functions and subroutines in other modules
I have some functions and subroutines define in Module1.
How would I go about using/calling these functions from Module 2??? (sorry if that is a newb question) |
Using functions and subroutines in other modules
Use the CALL function like this: Code: -------------------- Sub One() Msgbox "This is One, Next is Two",vbokonly,"Sub One" Call Two End Sub Sub Two() Msgbox "This is Two, Next is Three",vbokonly,"Sub Two" Call Three End Sub Sub Three() Msgbox "This is Three, Next is Four",vbokonly,"Sub Three" Call Four End Sub Sub Four() Msgbox "This is Four, End of messages!",vbokonly,"Sub Four" End Sub -------------------- Robert Crandal;571510 Wrote: I have some functions and subroutines define in Module1. How would I go about using/calling these functions from Module 2??? (sorry if that is a newb question) -- Simon Lloyd Regards, Simon Lloyd 'Microsoft Office Help' (http://www.thecodecage.com) ------------------------------------------------------------------------ Simon Lloyd's Profile: http://www.thecodecage.com/forumz/member.php?userid=1 View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=157884 Microsoft Office Help |
Using functions and subroutines in other modules
In Module2 simply call the Functions and Procedures as you would in Module1
but its often best to qualify you calls... Module1.Procedure1(x) x = Module1.Function1(x) etc, etc ... "Robert Crandal" wrote: I have some functions and subroutines define in Module1. How would I go about using/calling these functions from Module 2??? (sorry if that is a newb question) . |
All times are GMT +1. The time now is 10:32 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com