making subject and 1 resource mandatory

3 posts, 1 answers
  1. Reini
    Reini avatar
    16 posts
    Member since:
    Apr 2007

    Posted 05 May 2008 Link to this post

    hi all!

    maybe i'm missing something, but i need to have the subject and one on my resources mandatory when editing or inserting an appointment.

    how can i achieve that?

    i'm able to the event 'appointment_insert' to check if the subject is empty & also check the resource if is nothing....

    but when updating i always get the 'old' values in the 'appointment_update' event - so when some one has deleted the subject i cannot check or stop him from doing so...

    are there any examples i'm missing?

    please help me :-)
    thanks!
  2. Answer
    Peter
    Admin
    Peter avatar
    6637 posts

    Posted 08 May 2008 Link to this post

    Hi Reini,

    We couldn't reproduce the decribed problem with version 2008.1.415. The following code works as expected:
    protected void RadScheduler1_AppointmentUpdate(object sender, AppointmentUpdateEventArgs e)  
        {  
            if (e.ModifiedAppointment.Subject == "")  
                e.Cancel = true;  
        } 

    If there are any other factors we need to consider, please specify them.


    Peter
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Reini
    Reini avatar
    16 posts
    Member since:
    Apr 2007

    Posted 08 May 2008 Link to this post

    oh yes - now it's clear to me :-) that's what i said: 'i'm missing something'...

    i was not using the 'e.ModifiedAppointment' but the same code as in the 'insert' function: e.Appointment.... which was of course still the NOT modified one....

    thank you! works fine now!
Back to Top