public Number getPercentageWorkComplete ( ) { Number pct = ( Number ) getCachedValue ( AssignmentField . PERCENT_WORK_COMPLETE ) ; if ( pct == null ) { Duration actualWork = getActualWork ( ) ; Duration work = getWork ( ) ; if ( actualWork != null && work != null && work . getDuration ( ) != 0 ) { pct = Double . valueOf ( ( actualWork . getDuration ( ) * 100 ) / work . convertUnits ( actualWork . getUnits ( ) , getParentFile ( ) . getProjectProperties ( ) ) . getDuration ( ) ) ; set ( AssignmentField . PERCENT_WORK_COMPLETE , pct ) ; } } return pct ; }
The % Work Complete field contains the current status of a task expressed as the percentage of the task s work that has been completed . You can enter percent work complete or you can have Microsoft Project calculate it for you based on actual work on the task .