Resource Usage

J

Jan De Messemaeker

Hi,

It's evening round here and I don't have the time now but I'll send some
code tomorrow afternoon
Greets
 
W

Wil

Thanks Ed, my problem is that I want to store this information in only 1
projects, that's what I insist, but thanks anyway for all your opinions and
help

Best regards

"Ed Morrison" escribió:
 
J

Jan De Messemaeker

Hi!

I'll just give the specific MS project code I suppose (I hope) you can code
Excel VBA or passing this into VB (which I never practiced)


Dim TheAss as assignment
Dim XlApp as Excel.application
Dim TSBW as timescalevalues
Dim TSBWel as timescalevalue
Dim CumBW as double
dim ctr as integer

set xlapp=CreateObject "Excel.Application"
......

'The task is suppose dto be located let's call it AnyTask
'The example handles the 1st assignment of this task

Set TheAss=Anytask.assignments(1)
set TSBW=theass.timescaledata startdate:=anytask.start, _
enddate:=anytask.finish, type:=pjassignmenttimescaledbaselinework, _
timescaleunit:=pjtimescaledays

'Now find the address of the Excel Cell where to put the first of the values
'Let's call that Ro and Col
'similar logic may apply to addresses in Access tables

CumBW=0
ctr=0
For each TSBWel in TSBW
cumbw=cumbw+val(tsbwel)/60
xlapp.activesheet.cells(ro,col+ctr)=cumbw
ctr=ctr+1
next tsbwel
........

Hope this helps
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top