none
Set value for a workflow controlled custom field from withing the workflow using PSI RRS feed

  • Question

  • Hi,

    We are building a workflow for a new Enterprise Project Type. Requirement is that when a new project is created, a value (custom user-friendly project ID) is programmatically written to a workflow controlled custom field. The project then moves to the next stage where this field is set to Read-Only.

    Problem is that we do not succeed in setting the value programmatically from within this workflow.

    Problem description:

    • Project is created and workflow is fired. The custom field is read-write in this initial stage
    • Using PSI, our workflow tries to write the value to the custom field
    • No error is returned (not by PSI, not in event log, not is ULS), but the value is not written to the custom field

    If we set the field to 'workflow controlled = No', our code works.

    Has anyone experience with this scenario? Is this possible and supported? I can't seem to find much information about this in the SDK.
    Or is this not possible, and if not, is there an alternative to accomplish this?

    Thank you!
    Hans


    My EPM blog: Projectopolis
    Wednesday, March 9, 2011 8:06 AM
    Moderator

All replies

  • Hi,

    I am a beginner in EPM workflows but I think what happened with you is logical because you did not use the workflow activity called "UpdateProjectProperty" to set the ID value. You used the PSI so the Project Server does not know that this PSI caleld from work flow or third arty application.

    So "UpdateProjectProperty" activity and set "workflow controlled@" to yes.

    and tell us what happened with you.

    good luck.


    Twitter : @MShoubaki | people.bayt.com/mshoubaki
    Wednesday, March 9, 2011 10:05 AM
  • Hi Mohammad,

    According to our developer, this is exactly what he is doing is his code. The code runs fine, but the property is not updated.
    Have you been able to succefully update a project property with this approach?

    Thank you!
    Hans


    My EPM blog: Projectopolis
    Wednesday, March 9, 2011 11:12 AM
    Moderator
  • Sorry my friend I did not try it, but try to edit the project and check the ID value if is changed or not. I heard someone had this behavior too

    check this question:

    http://social.technet.microsoft.com/Forums/en-US/project2010custprog/thread/3f49ba89-6190-4bd2-93e6-f08d21ddb339


    Twitter : @MShoubaki | http://people.bayt.com/mshoubaki
    Wednesday, March 9, 2011 11:30 AM