Re: Nonworking hours
- From: John <mjensen@xxxxxxxxxxxx>
- Date: Thu, 21 Dec 2006 16:53:25 -0700
In article <52310D68-859C-4CE2-BC2A-E93FB8A6858F@xxxxxxxxxxxxx>,
Dan <Dan@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
Yes, it's running slower than I would wish. I have 15-20 projects sharing a
resource pool, and so to check for 450 days for each one whether each day is
working or not, takes a lot of time, when each project only has 10-15
nonworking days among those 450 that I'm checking.
Dan
Dan,
OK, but how often do you have to check it? Normally calendars don't
change, so once you have a count (or whatever data you want) for the
non-working days, you're done, right? I mean, it's not like you are
going to run a -90 to +360 count every day, week or month. The most you
should have to run it is maybe once a year.
John
Project MVP
.
"John" wrote:
In article <481E4AC9-9CE5-48C1-A84A-9E0BDCAE00CE@xxxxxxxxxxxxx>,
Dan <Dan@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
John,
Thank you for your response.
Right now I'm using a range of dates that starts 90 days before today and
ends 360 days after today, using a For loop to test each and every one of
those dates. I may have holidays defined that are outside the range of
the
start and end dates of the project, so I can't simply loop on the start
and
end of the project. Do you have any other suggestions that might make my
checking more efficient or fewer loops?
Dan
Dan,
As far as I know, the code must look at each day to determine if it is
working. Is your code not running fast enough or what is the real
problem?
John
Project MVP
"John" wrote:
In article <E1A73539-B5C9-46A6-8A2C-5EE4F9DF64D0@xxxxxxxxxxxxx>,
Dan <Dan@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
I am writing a VB program that accesses the data in my project files.
I
know
how to find out how many tasks are defined in a project and how to
access
the
data for each task. I can do the same thing for resources and
assignments. Is
there a way to find out how many dates are defined as nonworking and
get
the
data for those dates? Right now, I only know how to loop on a set of
dates
and check .Days(I).Working. Is there a simpler way to get a
collection of
only the dates for which .Days(I).Working is False?
Dan
Dan,
Probably not but I guess it depends on the construct of your code.
Maybe
it is not set up as efficiently as it could be.
John
Project MVP
- Follow-Ups:
- Re: Nonworking hours
- From: Dan
- Re: Nonworking hours
- References:
- Re: Nonworking hours
- From: John
- Re: Nonworking hours
- From: John
- Re: Nonworking hours
- From: Dan
- Re: Nonworking hours
- Prev by Date: Re: Nonworking hours
- Next by Date: Re: Nonworking hours
- Previous by thread: Re: Nonworking hours
- Next by thread: Re: Nonworking hours
- Index(es):
Relevant Pages
|