This is a migrated thread and some comments may be shown as answers.

Confirm appointment insert

1 Answer 57 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Bill
Top achievements
Rank 1
Bill asked on 02 Apr 2012, 09:24 PM
So I'm trying to use a RadWindowManager in conjuction with an appointment insert. So far I have the following:

VB Code-Behind:
Protected Sub RadScheduler1_AppointmentInsert(sender As Object, e As Telerik.Web.UI.AppointmentInsertEventArgs) Handles RadScheduler1.AppointmentInsert
            RadWindowManager1.RadConfirm("Server radconfirm: Are you sure?", "confirmCallBackFn", 330, 100, Nothing, "Server RadConfirm", Nothing)
End Sub

Javascript functions:
<script type="text/javascript">
    function schedulerFormCreated() {
            $telerik.$(".rsRecurrenceOptionList li:eq(4)").hide(); 
    }
      
        function confirmCallBackFn(arg)
    {
         return arg;
    }
      
    function OnClientAppointmentInserting(sender, eventArgs)
  {
    if(confirmCallBackFn())
        {
         eventArgs.set_cancel(false);
        }       
            else { eventArgs.set_cancel(true);
        }
  }
  
</script>

The problem I seem to be having is that the radconfirmation window isn't even being called upon appointment insert, therefore the javascript function is returning a null or undefined value. If the radconfirm is not even being displayed, I can't pass the true or false value on to the inserting client event in order to go ahead and insert or cancel the insert. Anybody have any insight or have a working version of this? Any help would be greatly appreciated!

1 Answer, 1 is accepted

Sort by
0
Plamen
Telerik team
answered on 05 Apr 2012, 03:35 PM
Hi Bill,

 
If you want to ask with confirmation window if an appointment should be inserted I will recommend you using functionality similar to the one in this demo.

If you want to use confirmation on server clicks on "Save" buttons you can refer to this demo.

Hope this will help you.

All the best,
Plamen Zdravkov
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Scheduler
Asked by
Bill
Top achievements
Rank 1
Answers by
Plamen
Telerik team
Share this question
or