issue updating an appointment that I reopen RRS feed

  • Question

  • Hi:

    I have an appointment that I am trying to update when the save as completed.  I can retrieve the appt no problem I can reopen it no problem

    When I go to update the appt i keep getting "3 is not a valid status code for state code appintmentstate.open on appointment"  Code worked fine in crm 3

    When I open the appt state code is set to 1.  Im not setting it to 3.  However I do notice that the appointment when i create it comes up as scheduled. 
    I reopen the appt with  below -- it keeps coming up as scheduled versus open.  When I update Im getting the 3 error.  How do I reopen an appt in crm 4?

    Dim OpenAppt As SetStateAppointmentRequest = New SetStateAppointmentRequest


    New Guid(Me.activityid.Value.ToString)



    Dim OpenApptResponse As SetStateAppointmentResponse = CType(crmService.Execute(OpenAppt), SetStateAppointmentResponse)

    OpenAppt.AppointmentState = AppointmentState.Open
    OpenAppt.AppointmentStatus = 1

    OpenAppt.EntityId =

    Monday, August 10, 2009 1:07 PM


All replies