none
SubmitStatusForResource for s_apid_sched_work gets ignored after the first time RRS feed

  • Question

  • I am attempting to write a custom program to update Work on an assignment (not actual work).

    I use the statusing service with the usual UpdateStatus and SubmitStatusForResource with a change xml like below:

    <Changes>
      <Proj ID="11444f27-83a9-e411-bfc2-00155d387f03">
        <Assn ID="a480753f-e0b2-e411-819f-080027003803" ResID="741f3743-0a19-e411-b611-00155d603122">
          <PeriodChange PID="251658246" Start="2015-08-01T00:00:00" End="2015-08-31T23:59:59">4140000</PeriodChange>
        </Assn>
      </Proj>
    </Changes>

    PID above refers to: s_apid_sched_work

    This works fine for "actual work", which uses a different PID in XML above, but when I try to use it to update "work", it only successful the first time. Any subsequent calls to change the work for the same period or other periods gets ignored by project server. No queue message, no error thrown by the code. It just goes nowhere. I can see that setting "work" on an assignment via this method is supported according to the following article.

    https://msdn.microsoft.com/en-us/library/office/bb428845%28v=office.14%29.aspx

    Can someone offer any suggestions? I have already set my task tracking mode to "Free Form" in PWA settings, so nothing should be preventing this type of update.

    Is this a BUG? Please help.


    Thursday, February 12, 2015 7:05 PM

Answers

All replies

  • Not tried it Carlos - but if you are updating using statusing I would suspect that would not normally expect a change to 'work' - but to either actual work or remaining work - the kind of fields that you would update through the UI.  For making a change to work you could probably do this through other PSI methods apart from statusing - but obviously depends if you want the change to go through approval or not.  Let me know how it goes Carlos.  Agree that the documentation appears to say this should 'work' - but try remaining work instead.

    Best regards,

    Brian.


    Blog | Facebook | Twitter | Posting is provided "AS IS" with no warranties, and confers no rights.
    Project Server TechCenter | Project Developer Center | Project Server Help | Project Product Page

    Thursday, February 12, 2015 7:19 PM
    Owner
  • Hi Brian,

    I hear what you are saying, but here is a bit more detail.

    I am not actually trying to update remaining work. I am building a UI that will let the user set different "work" hours per month. The current PWA UI does not let you do this. This can only be done with Project Pro, hence the custom UI.

    I would love to use other PSI methods, but as far as I know the Project Service only lets be set work on the assignment as a whole (from start to finish) and not on a timephase fashion as I am trying to do (by month). This is why I am going with the statusing service, it's not for the approvals features, but to gain access to set "work" on a timephase way on a specific assignment (by month). This works great for "actual work" as I have coded many times, but this is the first time I am trying to do it with "work".

    Do you see another way of accomplishing that? The statusing service seems like the best fit, but I think there is a BUG in it.

    Thursday, February 12, 2015 7:29 PM
  • Understood Carlos - but I would say this was not a bug - but a limitation.  If you use the UI for submitting status you also cannot edit 'work' (the Planned row) - just actual work.  You can however edit the scalar value if work in the left - just not the timephased on the right.

    I'm not aware of any programmatic way to do this timephasing of planned work.  I wonder if resource plans might give you what you need?

    Best regards,

    Brian.


    Blog | Facebook | Twitter | Posting is provided "AS IS" with no warranties, and confers no rights.
    Project Server TechCenter | Project Developer Center | Project Server Help | Project Product Page

    Thursday, February 12, 2015 7:44 PM
    Owner
  • Thanks Brian.

    I was willing to accept this as a limitation if it had not teased with the fact that it actually works for submitting the first time. I was able to set "60" hours for the month of July and it worked perfectly. Then I tried to update July to 64 hours, no luck. I tried to set 40 hours for August, no luck. It seems I can only do one update via statusing service. I am thinking maybe I just need to re-set something on the assignment to make it think it's the first time, but even if I ZERO out the planned work with project professional, as a test, it will will not let me set it subsequently. :(

    I went down the path of resource plans, but the limitation there is that it is not task specific. I can only do resource plans per resource, so that does not work with the client requirements because they want to assign this planned work on a task by task basis in the project plan.

    Am I just out of luck here?

    Thursday, February 12, 2015 7:55 PM