Home |
Search |
Today's Posts |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On Mar 8, 3:26*pm, "RB Smissaert"
wrote: If the function is called 7 times in the same procedure then you can do this: Dim lSum As Long lSum = lSum + GetUnAllocatedJobs("Monday") lSum = lSum + GetUnAllocatedJobs("Tuesday") etc. If it is called in different procedures then lSum has to be a Public (applies to whole workbook) or Private (applies to that module only) variable. RBS "MJKelly" wrote in message ... Thanks for the replies. Could you just explain how I use the function? macro1 does a number of things and calls the function 7 times... At the end of macro1, I want to tell the user the total number of unallocated jobs (all days added together). So, would this be msgbox getunallocatedjobs? I still only see this working by declaring a public variable to hold the unallocated jobs for Monday, then add Tuesday count to it and so on. *This being the value of x for each time the function is called? Thanks, Matt Excellent. Thanks very much. Kindest regards, Matt |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Going back to original location | Excel Discussion (Misc queries) | |||
Back to original Formating | Excel Programming | |||
Back to original file | Excel Programming | |||
Passing arguments to a sub routine... | Excel Programming | |||
using VBA to go back to the original value before the cell was changed | Excel Programming |