[Stackoverflow] [Progress OpenEdge ABL] How to export the start date and time in MS Project?

Status
Not open for further replies.
T

time pass

Guest
I am working with Progress 4gl(11.7) version where I came across a scenario where We are doing Job/task export from application to MS project. Everything is working fine but we have a problem in Percentage Complete where if the job/task duration is 1.5 days after exporting to MS Project its calculating 2 days which is changing the Percent Complete automatically. So I figured may be as we are exporting only date not time, calculation is also happening in Dates.

Now I tried to export the time as well in the start and end date. This is what I have tried

Code:
DEF VAR objPrj       AS COM-HANDLE NO-UNDO.
DEF VAR objActivePrj AS COM-HANDLE NO-UNDO.

CREATE "MSProject.Application" objPrj. /*Created a project object*/
objActivePrj = objPrj:ActiveProject(). /*Activated the project*/

objActiveTask = objActivePrj:Tasks:ADD("", vTaskId).  /*Add the Task*/
objActiveTask = objActivePrj:Tasks:Item(vTaskId).  /*Add the Task ID*/
objActiveTask:START  = DATETIME("05-30-2020 03:30 pm"). /*Added hardcoded date and time*/

which is working perfectly fine I am able to export this time in the MS Project.

Now if I do the similar assignment something like

Code:
objActiveTask:START  = DATETIME(STRING(02/24/24,"99-99-9999") + " " +  STRING(15:00, "HH:MM:SS"))

Where STRING(02/24/24,"99-99-9999") will be replaced by date variable and STRING(15:00, "HH:MM:SS") will be replaced by time variable.

The time and date is exporting but its exporting wrong like 02/29/2024 00:00 in MS project.

What could we do to export the time and the date correctly? If you have worked on any kind MS project Exporting Program please guide me. Thank you very much.

Continue reading...
 
Status
Not open for further replies.
Back
Top