It's all about the answers!

Ask a question

How to enter time tracking values by API

Berthold Kröger (7841923) | asked May 03 '13, 6:27 a.m.
retagged May 03 '13, 6:34 a.m. by Dinesh Kumar B (4.1k413)
Hi, does anybody know how to enter time tracking values by Java API?

RTC v.3.0.1

Accepted answer

permanent link
Ralph Schoon (63.0k33645) | answered Mar 31 '15, 10:42 a.m.
For anyone who searches for example, I created example code to access and modify the time tracking data for work items and published in this post:
Berthold Kröger selected this answer as the correct answer

3 other answers

permanent link
Lauren Hayward Schaefer (3.3k11727) | answered May 06 '13, 7:04 a.m.
Hi Berthold,
Are you talking about entering time into fields like time spent?  If so, you may find this post helpful:

Berthold Kröger commented May 08 '13, 9:38 a.m.

Hi Lauren, thank you for your answer but no, I was looking to maintain the time tracking values per weekday, not the accumulated value in attribute TimeSpent.

Lauren Hayward Schaefer commented May 10 '13, 6:38 a.m.

Hi Berthold,

Unfortunately, I don't understand what you mean.  Can you give an example? 

Berthold Kröger commented May 17 '13, 5:36 a.m.

In the Web UI you can open the Time tracking tab in a task work item and enter time spent values for each day. I would like to do the same by a Java API program to avoid double entering that data because we get this information from the SAP system.
Unfortunately I was not able to upload a screenshot to demonstrate it.

Lauren Hayward Schaefer commented May 17 '13, 6:55 a.m.

Hi Berthold,
Thanks for clarifying!  I'm not sure how to input time tracking information.  Perhaps this post could help get you started:

permanent link
Gabi mordov (634) | answered Jun 17 '14, 6:35 a.m.
 Hi Berthold,
i have the same issue.
did you find some answer to your post???
well i want to update our Time Track by external *.csv file.

if you have an answer or find some solution ill be glad to see it.


permanent link
Arne Bister (2.6k12832) | answered Jun 25 '14, 11:38 a.m.

if looking at the published RTC SDK (setup cp. e.g. Ralph Schoon's Blog) and Java Searching for TimeSheet you can find that the has a class BaseRTCReportTest.
There is a method: createTimesheetEntry that has sample code.  I would have guessed that some parts of it probably rely on internal API but so far I have not found anything. Seems to be all legit parts of the published RTC SDK.

Core method:
with: IWorkItemService workItemService
ITimeSheetEntry entry = workItemService.createTimeSheetEntry(projectArea);

and then
etc. etc.

If this is helpful please mark this answer accepted.

Your answer

Register or to post your answer.