Im confused as how this should work. I've setup a schedule and now want to add a dropdownlist to both the advanceinsert and inlineinsert. Everything works fine in the advanced form but I cant get the inilneform to work. Not sure how to get it going. I've looked at every demo as well as every forum post and cant seem to figure it out.
Any help would be great.
Any help would be great.
<
InlineInsertTemplate
>
<
div
>
<
asp:DropDownList
ID
=
"ddlOrganizations"
runat
=
"server"
Width
=
"238px"
></
asp:DropDownList
>
<
br
/>
<
telerik:RadTextBox
ID
=
"rtbSubject"
runat
=
"server"
TextMode
=
"MultiLine"
Columns
=
"35"
EmptyMessage
=
"Title"
Text='<%# Bind("Subject") %>'></
telerik:RadTextBox
>
<
br
/>
<
asp:LinkButton
ID
=
"InsertButton"
runat
=
"server"
CommandName
=
"Insert"
>
Submit
</
asp:LinkButton
>
<
asp:LinkButton
ID
=
"InsertMoreButton"
runat
=
"server"
CommandName
=
"More"
>
Advanced
</
asp:LinkButton
>
<
asp:LinkButton
ID
=
"CancelButton"
runat
=
"server"
CommandName
=
"Cancel"
>
Cancel
</
asp:LinkButton
>
</
div
>
</
InlineInsertTemplate
>
protected
void
Page_Load(
object
sender, EventArgs e)
{
if
(!IsPostBack)
{
SetupResources();
}
}
private
void
SetupResources()
{
ResourceType resType =
new
ResourceType();
resType.ForeignKeyField =
"OrganizationID"
;
resType.DataSource = Organizations.OrganizationList(
false
);
resType.KeyField =
"OrganizationID"
;
resType.Name =
"Organization"
;
resType.TextField =
"OrganizationName"
;
rsProjectSchedule.ResourceTypes.Add(resType);
}
protected
void
rsProjectSchedule_FormCreated(
object
sender, SchedulerFormCreatedEventArgs e)
{
if
(e.Container.Mode == SchedulerFormMode.Insert)
{
DropDownList ddl = (DropDownList)e.Container.FindControl(
"ddlOrganizations"
);
ddl.DataSource = Organizations.OrganizationList(
false
);
ddl.DataTextField =
"OrganizationName"
;
ddl.DataValueField =
"OrganizationID"
;
ddl.DataBind();
}
}