Hello,
I'm using the scheduler with a few custom attributes to handle some additional fields. Here's an example below.
When I perform the insert (the edit works the same way), I am handling the "AppointmentInsert" event and accessing the values with e.Appointment.Attributes("CustomAttribute").
For the AdminNotes and PublicNotes, this gets a value, for the AllocationGroupID and SlotCode, it just comes back as an empty string. Everything is otherwise identical and I can't figure it out here...
Anybody have any ideas?
Thanks,
Mike
I'm using the scheduler with a few custom attributes to handle some additional fields. Here's an example below.
When I perform the insert (the edit works the same way), I am handling the "AppointmentInsert" event and accessing the values with e.Appointment.Attributes("CustomAttribute").
For the AdminNotes and PublicNotes, this gets a value, for the AllocationGroupID and SlotCode, it just comes back as an empty string. Everything is otherwise identical and I can't figure it out here...
Anybody have any ideas?
Thanks,
Mike
Private Sub roomSlots_AppointmentInsert(sender As Object, e As Telerik.Web.UI.AppointmentInsertEventArgs) Handles roomSlots.AppointmentInsert Dim newSlot As New ProgramSlotInfo Dim ctlSlots As New ProgramSlotController With newSlot .ConferenceID = ConferenceID .StartTime = e.Appointment.Start .EndTime = e.Appointment.End .LocationRoomID = LocationRoomID .SlotCode = e.Appointment.Attributes("SlotCode") .AdminNotes = e.Appointment.Attributes("AdminNotes") .PublicNotes = e.Appointment.Attributes("PublicNotes") .AllocationGroupID = e.Appointment.Attributes("AllocationGroupID") End With ctlSlots.AddProgramSlot(newSlot)End Sub<telerik:RadScheduler runat="server" ID="roomSlots" AllowEdit="True" AllowDelete="True" AllowInsert="True" EnableDatePicker="False" SelectedView="WeekView" ShowAllDayRow="False" Width="100%" DataKeyField="ProgramSlotID" DataSubjectField="SlotCode" DataStartField="StartTime" DataEndField="EndTime" StartInsertingInAdvancedForm="true" EnableCustomAttributeEditing="true" CustomAttributeNames="PublicNotes,SlotCode,AdminNotes,AllocationGroupID" MinutesPerRow="60"> <AdvancedInsertTemplate> <h2 class="dnnFormSectionHead"><asp:Label runat="server" ID="lblAddSlotHeader" resourcekey="AddSlotHeader" Text="Add New Slot"></asp:Label></h2> <div class="dnnForm"> <div class="dnnFormItem"> <dnn:label runat="server" id="lblStartTime" text="Start" resourcekey="StartLabel"></dnn:label> <telerik:RadDateTimePicker runat="server" ID="startTime" SelectedDate='<%#bind("Start") %>' TimeView-Interval="00:15:00" TimeView-Columns="4" TimeView-StartTime="6:00:00"></telerik:RadDateTimePicker> </div> <div class="dnnFormItem"> <dnn:label runat="server" id="lblEndTime" text="End" resourcekey="EndLabel"></dnn:label> <telerik:RadDateTimePicker runat="server" ID="endTime" SelectedDate='<%#bind("End") %>' TimeView-Interval="00:15:00" TimeView-Columns="4" TimeView-StartTime="6:00:00"></telerik:RadDateTimePicker> </div> <div class="dnnFormItem"> <dnn:label runat="server" id="lblSlotCode" text="Slot Code" resourcekey="SlotCodeLabel"></dnn:label> <asp:TextBox runat="server" ID="txtSlotCode" Text='<%# Bind("SlotCode") %>'></asp:TextBox> </div> <div class="dnnFormItem"> <dnn:label runat="server" id="lblAllocationGroup" text="Allocation Group" resourcekey="AllocationGroupLabel"></dnn:label> <telerik:RadComboBox runat="server" ID="cboAllocationGroup" DataTextField="GroupName" DataValueField="AllocationGroupID" DataSourceID="dsAllocationGroups" selectedValue='<%#bind("AllocationGroupID") %>'></telerik:RadComboBox> </div> <div class="dnnFormItem"> <dnn:label runat="server" id="lblPublicNotes" text="Public Notes" resourcekey="PublicNotesLabel"></dnn:label> <asp:TextBox runat="server" ID="txtPublicNotes" TextMode="MultiLine" Text='<%#Bind("PublicNotes") %>'></asp:TextBox> </div> <div class="dnnFormItem"> <dnn:label runat="server" id="lblAdminNotes" text="Administrative Notes" resourcekey="AdminNotesLabel"></dnn:label> <asp:TextBox runat="server" ID="TextBox1" TextMode="MultiLine" Text='<%#Bind("AdminNotes") %>'></asp:TextBox> </div> <asp:LinkButton runat="server" ID="lnkCreateSlot" CommandName="Insert" Text="Create Slot" CssClass="dnnPrimaryAction"></asp:LinkButton> <asp:LinkButton runat="server" ID="lnkCancelInsert" CommandName="Cancel" Text="Cancel" CssClass="dnnSecondaryAction"></asp:LinkButton> </div> </AdvancedInsertTemplate>