<
telerik:RadScheduler ID="rsDaySchedule" Height="2093px" BorderStyle="None" ShowNavigationPane="false" Width ="100%" ShowViewTabs="false" AllowDelete="False" AllowEdit="true" AllowInsert="False" HoursPanelTimeFormat="h:mmtt" NumberOfHoveredRows="1" RowHeight ="52px" DayStartTime="8:30:00" DayEndTime="13:00:00" SelectedView="DayView" OnAppointmentDataBound="rsDaySchedule_AppointmentDataBound" OnAppointmentCommand="rsDaySchedule_AppointmentCommand" OnAppointmentClick="rsDaySchedule_AppointmentClick" MinutesPerRow="15" DataSubjectField="OrgName" DataKeyField="ScheduleEntryID" DataStartField="startTime" DataEndField="endTime" CustomAttributeNames="Desicions,DayLeft,ScheduleEntryID,OrgID" EnableCustomAttributeEditing="true" runat="server" style="left: 0px; top:0px" Skin
<AppointmentTemplate >
<asp:Table ID="Table1" CssClass="OrgInfo" BorderStyle="NotSet" runat="server" Width ="100%" Height="52px" >
<asp:TableRow Height="30px">
<asp:TableCell Width ="109px">
<asp:Label ID="lblOrgName" runat ="server" Text="Organization Name: "></asp:Label>
</asp:TableCell>
<asp:TableCell Width ="339px">
<asp:Label ID="txtOrgName" runat ="server" Font-Bold="true" Text='<%# Eval("Subject") %>'></asp:Label>
</asp:TableCell>
<asp:TableCell Width ="228px">
<asp:Label ID="lblDecision" runat ="server" Text="Decision: "></asp:Label>
<asp:Label ID="txtDecision" runat ="server" Font-Bold="true" Text='<%# Eval("Desicions") %>'></asp:Label>
</asp:TableCell>
<asp:TableCell Width="82px">
<asp:Label ID="lblDayLeft" runat ="server" Text="Days Left: "></asp:Label>
<asp:Label ID="txtDayLeft" runat ="server" Font-Bold="true" Text='<%# Eval("DayLeft") %>'></asp:Label>
<asp:HiddenField ID="hdScheduleEntryID" Value ='<%# Eval("ScheduleEntryID") %>' runat="server" />
<asp:HiddenField ID="hdOrgID" Value ='<%# Eval("OrgID") %>' runat="server"/>
</asp:TableCell>
</asp:TableRow>
<asp:TableRow Height="21px">
<asp:TableCell >
</asp:TableCell>
<asp:TableCell>
</asp:TableCell>
<asp:TableCell >
<sp:LinkButton ID="lbtnResche" runat="server" ForeColor="Blue" CommandName="Reschedule" Text="Reschedule"></asp:LinkButton>
<asp:LinkButton ID="lbtnRatings" runat="server" ForeColor="Blue" CommandName="EditRating" Enabled="True" Text="Edit Ratings"></asp:LinkButton> <asp:LinkButton ID="lbtnNext" runat="server" ForeColor="Blue" CommandName="More" Text="More info ..." > </asp:LinkButton>
</asp:TableCell>
</asp:TableRow>
</asp:Table>
</AppointmentTemplate>
</telerik:RadScheduler>
My requestion is "How to find the controls in my AppointmentTemplate from AppointmentDataBound?"
How come in my
Protected Su
b rsDaySchedule_AppointmentDataBound(ByVal sender As Object, ByVal e As
Dim lbtnRatings As LinkButton = CType(e.Appointment.AppointmentControls(0).FindControl("lbtnRatings"), LinkButton)
I get error message -- Index was out of range.e.Appointment.AppointmentControls.count =0 always !
Please help ! Thanks a lot!
<
telerik:RadScheduler
ID
=
"rsDaySchedule"
Height
=
"2093px"
BorderStyle
=
"None"
ShowNavigationPane
=
"false"
Width
=
"100%"
ShowViewTabs
=
"false"
AllowDelete
=
"False"
AllowEdit
=
"true"
AllowInsert
=
"False"
HoursPanelTimeFormat
=
"h:mmtt"
NumberOfHoveredRows
=
"1"
RowHeight
=
"52px"
DayStartTime
=
"8:30:00"
DayEndTime
=
"13:00:00"
SelectedView
=
"DayView"
OnAppointmentDataBound
=
"rsDaySchedule_AppointmentDataBound"
OnAppointmentCommand
=
"rsDaySchedule_AppointmentCommand"
OnAppointmentClick
=
"rsDaySchedule_AppointmentClick"
MinutesPerRow
=
"15"
DataSubjectField
=
"OrgName"
DataKeyField
=
"ScheduleEntryID"
DataStartField
=
"startTime"
DataEndField
=
"endTime"
CustomAttributeNames
=
"Desicions,DayLeft,ScheduleEntryID,OrgID"
EnableCustomAttributeEditing
=
"true"
runat
=
"server"
style
=
"left: 0px; top:0px"
Skin
=
"Sunset"
>
<
AppointmentTemplate
>
<
asp:Table
ID
=
"Table1"
CssClass
=
"OrgInfo"
BorderStyle
=
"NotSet"
runat
=
"server"
Width
=
"100%"
Height
=
"52px"
>
<
asp:TableRow
Height
=
"30px"
>
<
asp:TableCell
Width
=
"109px"
>
<
asp:Label
ID
=
"lblOrgName"
runat
=
"server"
Text
=
"Organization Name: "
></
asp:Label
>
</
asp:TableCell
>
<
asp:TableCell
Width
=
"339px"
>
<
asp:Label
ID
=
"txtOrgName"
runat
=
"server"
Font-Bold
=
"true"
Text='<%# Eval("Subject") %>'></
asp:Label
>
</
asp:TableCell
>
<
asp:TableCell
Width
=
"228px"
>
<
asp:Label
ID
=
"lblDecision"
runat
=
"server"
Text
=
"Decision: "
></
asp:Label
>
<
asp:Label
ID
=
"txtDecision"
runat
=
"server"
Font-Bold
=
"true"
Text='<%# Eval("Desicions") %>'></
asp:Label
>
</
asp:TableCell
>
<
asp:TableCell
Width
=
"82px"
>
<
asp:Label
ID
=
"lblDayLeft"
runat
=
"server"
Text
=
"Days Left: "
></
asp:Label
>
<
asp:Label
ID
=
"txtDayLeft"
runat
=
"server"
Font-Bold
=
"true"
Text='<%# Eval("DayLeft") %>'></
asp:Label
>
<
asp:HiddenField
ID
=
"hdScheduleEntryID"
Value ='<%# Eval("ScheduleEntryID") %>' runat="server" />
<
asp:HiddenField
ID
=
"hdOrgID"
Value ='<%# Eval("OrgID") %>' runat="server" />
</
asp:TableCell
>
</
asp:TableRow
>
<
asp:TableRow
Height
=
"21px"
>
<
asp:TableCell
>
</
asp:TableCell
>
<
asp:TableCell
>
</
asp:TableCell
>
<
asp:TableCell
>
<
asp:LinkButton
ID
=
"lbtnResche"
runat
=
"server"
ForeColor
=
"Blue"
CommandName
=
"Reschedule"
Text
=
"Reschedule"
></
asp:LinkButton
>
<
asp:LinkButton
ID
=
"lbtnRatings"
runat
=
"server"
ForeColor
=
"Blue"
CommandName
=
"EditRating"
Enabled
=
"True"
Text
=
"Edit Ratings"
></
asp:LinkButton
>
<
asp:LinkButton
ID
=
"lbtnNext"
runat
=
"server"
ForeColor
=
"Blue"
CommandName
=
"More"
Text
=
"More info ..."
> </
asp:LinkButton
>
</
asp:TableCell
>
</
asp:TableRow
>
</
asp:Table
>
</
AppointmentTemplate
>
</
telerik:RadScheduler
>
My question: How to find my control lbtnRatings form
Protected Sub rsDaySchedule_AppointmentDataBound(ByVal sender As Object, ByVal e As SchedulerEventArgs)
Thank you very much for your help in advance!
Susan
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="wishListToolTip.aspx.cs" Inherits="WebApplication2.WebForm1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<
html
xmlns
=
"http://www.w3.org/1999/xhtml"
>
<
head
runat
=
"server"
>
<
title
>Wish List ToolTips</
title
>
</
head
>
<
body
>
<
form
id
=
"form1"
runat
=
"server"
>
<
telerik:RadScriptManager
ID
=
"RadScriptManager1"
runat
=
"server"
></
telerik:RadScriptManager
>
<
telerik:RadToolTipManager
ID
=
"RadToolTipManager1"
runat
=
"server"
RelativeTo
=
"Element"
Position
=
"TopLeft"
Width
=
"250"
Height
=
"50"
AutoTooltipify
=
"True"
OffsetY
=
"12"
OffsetX
=
"-400"
>
</
telerik:RadToolTipManager
><
br
> <
br
/><
br
/><
br
/><
br
/><
br
><
br
><
br
>
<
asp:CheckBox
ID
=
"CheckBox7"
runat
=
"server"
text
=
"This is my placeholder text"
ToolTip
=
"This is my placesholder tooltip text"
/><
br
/><
br
/><
br
> <
br
/><
br
/><
br
/><
br
/><
br
/><
br
/><
br
/><
br
/><
br
>
</
form
>
</
body
>
</
html
>
<
telerik:RadCalendar
id
=
"DatePicker1"
runat
=
"server"
Skin
=
"Black"
EnableMultiSelect
=
"False"
Width
=
"400"
FirstDayOfWeek
=
"Monday"
>
</
telerik:RadCalendar
><
br
/>
<
br
/>
<
telerik:RadCalendar
id
=
"DatePicker2"
runat
=
"server"
Skin
=
"Black"
EnableMultiSelect
=
"False"
Width
=
"400"
FirstDayOfWeek
=
"Monday"
DayNameFormat
=
"Short"
>
</
telerik:RadCalendar
>
function
getEventDatesFromController()
{
var
returnData = $.ajax(
{
type:
"POST"
,
url:
"/Events/GetRadEventDatesByDateRange"
,
data:
"startDate="
+
"1/1/2000"
+
"&endDate="
+
"1/1/2100"
,
success:
function
(result) {
var
xml;
debugger
if
(
typeof
data ==
"string"
) {
xml =
new
ActiveXObject(
"Microsoft.XMLDOM"
);
xml.async =
false
;
xml.loadXML(data);
}
else
{
xml = result;
returnData = result;
var
ctrlEventCalendar = <%= ctrlEventCalendar.ClientID %>;
ctrlEventCalendar.selectDates(returnData,
true
); <-- Fails!!!, so does the following
for
loop
for
(
var
i = 0; i < returnData.length; i++) {
ctrlEventCalendar.SelectDate(returnData[i],
true
);
}
}
if
(result.success) {
alert(
"Controller Called Successfully"
);
},
error:
function
(req, status, error) {
alert("Sorry! Problem calling Event Controller
}
});
return
returnData;
}
<
div
class
=
"box-leftEventCalendar"
>
<
telerik:RadCalendar
runat
=
"server"
ID
=
"ctrlEventCalendar"
Style
=
"margin: 6px auto 0"
EnableMultiSelect
=
"false"
>
</
telerik:RadCalendar
>
</
div
>
<telerik:RadGrid runat="server" ID="rdGd1" EnableEmbeddedSkins="true"
skin="MySkin" GridLines="None">
As soon as I open this page, I highlight the 0000 entry shown above and type in 0032
Expecting it to find ‘0032 – Chubb Foundation’
Instead it displays ‘003200 – Bryman College’, but notice that Bryman College in the dropdown (up) is 3200.
If I hit the enter key to ‘accept’ this entry, the display changes to
I think it is not taking care of initial zeros in the search. Please let us know as it is a very important issue for you
Thanks very much and Regards,