
MadhuSudhan
Top achievements
Rank 1
MadhuSudhan
asked on 13 May 2011, 07:27 AM
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" DefaultLoadingPanelID="RadAjaxLoadingPanel1">
<ajaxsettings>
<telerik:AjaxSetting AjaxControlID="grdInProcess">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdInProcess" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
</ajaxsettings>
</telerik:RadAjaxManager>
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Skin="Default"/>
.................
<cc1:SJRadGrid ID="grdInProcess" runat="server" gridwidth="100%" Height="100%" OnNeedDataSource="GetPersonnelBudget"
AutoGenerateColumns="false" AllowSorting="true" Skin="Grants" EnableEmbeddedSkins="false" PageSize="10" Width="100%">
<MasterTableView AllowSorting="true" AllowMultiColumnSorting="false" DataKeyNames="EmployeeId"
AllowPaging="true" PageSize="10" Width="100%" BorderWidth="1" >
<Columns>
<cc1:CustomFilteringTemplateColumn HeaderText="Funding Source" HeaderStyle-HorizontalAlign="Left" HeaderStyle-Wrap="false"
HeaderStyle-Width="30%" AllowFiltering="false" UniqueName="FundingSource">
<ItemTemplate>
<asp:LinkButton ID="lblFundingSource" runat="server" Width="100" Text='<%# DataBinder.Eval(Container.DataItem,"FundingSource")%>' Onclick="show()"></asp:Label>
</ItemTemplate>
</cc1:CustomFilteringTemplateColumn>
</Columns>
</MasterTableView>
</cc1:SJRadGrid>
..........
show() :
In show method i am invoking a modal popup to display.
As this grid kept in RadAjaxManager, modal pop up is not displaying. Please help me out to get display of showing the Modal pop up even when kept in RadAjaxManager.
<ajaxsettings>
<telerik:AjaxSetting AjaxControlID="grdInProcess">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdInProcess" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
</ajaxsettings>
</telerik:RadAjaxManager>
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Skin="Default"/>
.................
<cc1:SJRadGrid ID="grdInProcess" runat="server" gridwidth="100%" Height="100%" OnNeedDataSource="GetPersonnelBudget"
AutoGenerateColumns="false" AllowSorting="true" Skin="Grants" EnableEmbeddedSkins="false" PageSize="10" Width="100%">
<MasterTableView AllowSorting="true" AllowMultiColumnSorting="false" DataKeyNames="EmployeeId"
AllowPaging="true" PageSize="10" Width="100%" BorderWidth="1" >
<Columns>
<cc1:CustomFilteringTemplateColumn HeaderText="Funding Source" HeaderStyle-HorizontalAlign="Left" HeaderStyle-Wrap="false"
HeaderStyle-Width="30%" AllowFiltering="false" UniqueName="FundingSource">
<ItemTemplate>
<asp:LinkButton ID="lblFundingSource" runat="server" Width="100" Text='<%# DataBinder.Eval(Container.DataItem,"FundingSource")%>' Onclick="show()"></asp:Label>
</ItemTemplate>
</cc1:CustomFilteringTemplateColumn>
</Columns>
</MasterTableView>
</cc1:SJRadGrid>
..........
show() :
In show method i am invoking a modal popup to display.
As this grid kept in RadAjaxManager, modal pop up is not displaying. Please help me out to get display of showing the Modal pop up even when kept in RadAjaxManager.
9 Answers, 1 is accepted
0

Tomasz
Top achievements
Rank 1
answered on 13 May 2011, 09:29 AM
try add the following setting
<<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdInProcess" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdInProcess" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
0

MadhuSudhan
Top achievements
Rank 1
answered on 13 May 2011, 12:47 PM
I added the code which you suggested, but for telerik prefix there was no AjaxSetting control found message was suggesting at the time of adding in source code. However when kept the same ode there was no error shown nor modal pop up.
0

Tomasz
Top achievements
Rank 1
answered on 13 May 2011, 01:52 PM
no try add
to RadAjaxManager on your .aspx page
<
telerik:AjaxSetting
AjaxControlID
=
"RadAjaxManager1"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"grdInProcess"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
0

MadhuSudhan
Top achievements
Rank 1
answered on 13 May 2011, 02:17 PM
Hi tomasz, Thank you for responding very quickly for my post. Yes i have tries that after i posted second time and tested but it was not showing the modal pop.
here is my complete source code :
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" DefaultLoadingPanelID="RadAjaxLoadingPanel1">
<ajaxsettings>
<telerik:AjaxSetting AjaxControlID="grdPersonnelBudget">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdPersonnelBudget" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdPersonnelBudget" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
</ajaxsettings>
</telerik:RadAjaxManager>
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Skin="Default"/>
Grid :
<cc1:SJRadGrid ID="grdPersonnelBudget" runat="server" gridwidth="100%" Height="100%" OnNeedDataSource="GetPersonnelBudget"
AutoGenerateColumns="false" AllowSorting="true" Skin="Grants" EnableEmbeddedSkins="false" PageSize="10" Width="100%">
<MasterTableView AllowSorting="true" AllowMultiColumnSorting="false" DataKeyNames="EmployeeId"
AllowPaging="true" PageSize="10" Width="100%" BorderWidth="1" >
<Columns>
<cc1:CustomFilteringTemplateColumn HeaderText="Employee" HeaderStyle-HorizontalAlign="Left"
HeaderStyle- Width="16%" SortExpression="Employee" AllowFiltering="false" ItemStyle-HorizontalAlign="Left">
<ItemTemplate>
<asp:LinkButton ID="lnkEmployee" runat="server" CommandName="EDITEMPLOYEE" ToolTip="Click to show Curent labor distribution"
OnClick="lnkEmployee_Click" Text=' <%#Eval("Employee") %>'></asp:LinkButton>
</ItemTemplate>
</cc1:CustomFilteringTemplateColumn>
</Columns>
</MasterTableView>
<ClientSettings>
<Selecting AllowRowSelect="True"></Selecting>
<ClientEvents OnGridCreated="PbGridCreated" OnRowSelected="PbRowSelected"></ClientEvents>
</ClientSettings>
</cc1:SJRadGrid>
Code :
protected void lnkEmployee_Click(object sender, EventArgs e)
{
LinkButton lnkbutton = sender as LinkButton;
GridDataItem dataItem = (GridDataItem)lnkbutton.Parent.Parent;
lblEmpName.Text = lnkbutton.Text + " :";
LoadEmployee(int.Parse(grdPersonnelBudget.MasterTableView.DataKeyValues[dataItem.ItemIndex]["EmployeeId"].ToString()));
}
private void LoadEmployee(int employeeID)
{
if (Session["EmployeeLabDist"] == null)
{
using (EmployeeLaborDistributionList objEmployeeLabDistList = new EmployeeLaborDistributionList())
{
objEmployeeLabDistList.Load(employeeID);
Session["EmployeeLabDist"] = objEmployeeLabDistList;
grdCurrentLabDist.DataSource = objEmployeeLabDistList;
grdCurrentLabDist.DataBind();
}
}
else
{
EmployeeLaborDistributionList objEmployeeLabDistList = Session["EmployeeLabDist"] as EmployeeLaborDistributionList;
using (objEmployeeLabDistList)
{
grdCurrentLabDist.DataSource = objEmployeeLabDistList;
grdCurrentLabDist.DataBind();
}
}
currentPopup.Enabled = true;
currentPopup.Show();
hdnEmployee.Value = employeeID.ToString();
}
I am getting the data perfectly and binding the grid also, only the modal pop up is not displaying. Please check my code patiently and suggest me further.
here is my complete source code :
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" DefaultLoadingPanelID="RadAjaxLoadingPanel1">
<ajaxsettings>
<telerik:AjaxSetting AjaxControlID="grdPersonnelBudget">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdPersonnelBudget" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdPersonnelBudget" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
</ajaxsettings>
</telerik:RadAjaxManager>
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Skin="Default"/>
Grid :
<cc1:SJRadGrid ID="grdPersonnelBudget" runat="server" gridwidth="100%" Height="100%" OnNeedDataSource="GetPersonnelBudget"
AutoGenerateColumns="false" AllowSorting="true" Skin="Grants" EnableEmbeddedSkins="false" PageSize="10" Width="100%">
<MasterTableView AllowSorting="true" AllowMultiColumnSorting="false" DataKeyNames="EmployeeId"
AllowPaging="true" PageSize="10" Width="100%" BorderWidth="1" >
<Columns>
<cc1:CustomFilteringTemplateColumn HeaderText="Employee" HeaderStyle-HorizontalAlign="Left"
HeaderStyle- Width="16%" SortExpression="Employee" AllowFiltering="false" ItemStyle-HorizontalAlign="Left">
<ItemTemplate>
<asp:LinkButton ID="lnkEmployee" runat="server" CommandName="EDITEMPLOYEE" ToolTip="Click to show Curent labor distribution"
OnClick="lnkEmployee_Click" Text=' <%#Eval("Employee") %>'></asp:LinkButton>
</ItemTemplate>
</cc1:CustomFilteringTemplateColumn>
</Columns>
</MasterTableView>
<ClientSettings>
<Selecting AllowRowSelect="True"></Selecting>
<ClientEvents OnGridCreated="PbGridCreated" OnRowSelected="PbRowSelected"></ClientEvents>
</ClientSettings>
</cc1:SJRadGrid>
Code :
protected void lnkEmployee_Click(object sender, EventArgs e)
{
LinkButton lnkbutton = sender as LinkButton;
GridDataItem dataItem = (GridDataItem)lnkbutton.Parent.Parent;
lblEmpName.Text = lnkbutton.Text + " :";
LoadEmployee(int.Parse(grdPersonnelBudget.MasterTableView.DataKeyValues[dataItem.ItemIndex]["EmployeeId"].ToString()));
}
private void LoadEmployee(int employeeID)
{
if (Session["EmployeeLabDist"] == null)
{
using (EmployeeLaborDistributionList objEmployeeLabDistList = new EmployeeLaborDistributionList())
{
objEmployeeLabDistList.Load(employeeID);
Session["EmployeeLabDist"] = objEmployeeLabDistList;
grdCurrentLabDist.DataSource = objEmployeeLabDistList;
grdCurrentLabDist.DataBind();
}
}
else
{
EmployeeLaborDistributionList objEmployeeLabDistList = Session["EmployeeLabDist"] as EmployeeLaborDistributionList;
using (objEmployeeLabDistList)
{
grdCurrentLabDist.DataSource = objEmployeeLabDistList;
grdCurrentLabDist.DataBind();
}
}
currentPopup.Enabled = true;
currentPopup.Show();
hdnEmployee.Value = employeeID.ToString();
}
I am getting the data perfectly and binding the grid also, only the modal pop up is not displaying. Please check my code patiently and suggest me further.
0

MadhuSudhan
Top achievements
Rank 1
answered on 19 May 2011, 10:57 AM
I have added following code as per your suggestion but still unable to get the modal pop up. Please help me out
<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdPersonnelBudget" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdPersonnelBudget" LoadingPanelID="RadAjaxLoadingPanel1"/>
</UpdatedControls>
</telerik:AjaxSetting>
0

Jayesh Goyani
Top achievements
Rank 2
answered on 19 May 2011, 02:48 PM
HI MadhuSudhan,
Thanks,
Jayesh Goyani
<
telerik:RadAjaxManager
ID
=
"RadAjaxManager1"
runat
=
"server"
>
<
AjaxSettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"grdCurrentLabDist"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"grdCurrentLabDist"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"currentPopup"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
AjaxSettings
>
</
telerik:RadAjaxManager
>
// OR
<
telerik:RadAjaxManager
ID
=
"RadAjaxManager1"
runat
=
"server"
>
<
AjaxSettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"grdPersonnelBudget"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"grdPersonnelBudget"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"currentPopup"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
AjaxSettings
>
</
telerik:RadAjaxManager
>
Thanks,
Jayesh Goyani
0

MadhuSudhan
Top achievements
Rank 1
answered on 19 May 2011, 06:28 PM
<
telerik:RadAjaxManager
ID
=
"RadAjaxManager1"
runat
=
"server"
>
<AjaxSettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"grdPersonnelBudget"
>
<
UpdatedControls
>
<telerik:AjaxUpdatedControl
ControlID
=
"grdPersonnelBudget"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"currentPopup"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
AjaxSettings
>
</
telerik:RadAjaxManager
>
I have added this and checked but the modal pop up in not showing. Here currentPopup is Modal popup enterder id. When kept this i am getting a error. Instead of currentPopup if i kept panel id then no modal popup is showing.
To get you the issue more clearly here i am explaining once again.
I have a grid called grdPersonnelBudget, into this once of the column has Hyperlink button, on Hyperlink click event i am showing a panel which is kept in <
telerik:RadAjaxManager
ID
=
"RadAjaxManager1"
runat
=
"server"
>
<AjaxSettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"grdPersonnelBudget"
>
<
UpdatedControls
>
<telerik:AjaxUpdatedControl
ControlID
=
"grdPersonnelBudget"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"currentPopup"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
AjaxSettings
>
</
telerik:RadAjaxManager
>
I have added this and checked but the modal pop up in not showing.
To get you the issue more clearly here i am explaining once again.
I have a grid called grdPersonnelBudget, into this once of the column
has Hyperlink button, on Hyperlink click event i am showing a panel
which is kept in modal pop extender. As my grid is kept in
RadAjaxManager no modal pop up is showing. If i remove my grid fromRadAjaxManager
modal pop up is showing perfectly and i need to keep this grid inRadAjaxManager. So please go through this process and help me out.
0
Accepted

Jayesh Goyani
Top achievements
Rank 2
answered on 21 May 2011, 08:20 AM
Hi MadhuSudhan,
Thanks,
Jayesh Goyani
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<
telerik:RadAjaxManager
ID
=
"RadAjaxManager1"
runat
=
"server"
>
<
AjaxSettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"grdPersonnelBudget"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"grdPersonnelBudget"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"pnlMpMain"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
AjaxSettings
>
</
telerik:RadAjaxManager
>
<
table
>
<
tr
>
<
td
>
<
telerik:RadGrid
runat
=
"server"
ID
=
"grdPersonnelBudget"
OnItemCommand
=
"grdPersonnelBudget_ItemCommand"
>
<
MasterTableView
>
<
Columns
>
<
telerik:GridTemplateColumn
UniqueName
=
"ViewForm"
>
<
ItemTemplate
>
<
asp:LinkButton
ID
=
"lnkViewDetail"
runat
=
"server"
CommandName
=
"ViewDetail"
CommandArgument='<%# Eval("ID") %>' Text='<%# Eval("ID") %>'
></
asp:LinkButton
>
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
</
Columns
>
</
MasterTableView
>
</
telerik:RadGrid
>
</
td
>
</
tr
>
<
tr
>
<
td
>
<
asp:Panel
ID
=
"pnlMpMain"
runat
=
"server"
>
<
cc1:ModalPopupExtender
TargetControlID
=
"forpopup"
ID
=
"mpPreview"
runat
=
"server"
Enabled
=
"True"
BackgroundCssClass
=
"modalBackground"
PopupControlID
=
"pnlModal"
CancelControlID
=
"btnCancel"
DropShadow
=
"true"
>
</
cc1:ModalPopupExtender
>
<
asp:LinkButton
ID
=
"forpopup"
runat
=
"server"
></
asp:LinkButton
>
<
asp:Panel
ID
=
"pnlModal"
runat
=
"server"
CssClass
=
"modalPopup"
Style
=
"display: none;"
>
<%--
Your Code come shold here !!
--%>
</
asp:Panel
>
</
asp:Panel
>
</
td
>
</
tr
>
</
table
>
protected
void
grdPersonnelBudget_ItemCommand(
object
sender, GridCommandEventArgs e)
{
try
{
if
(e.CommandName ==
"ViewDetail"
)
{
// your code part
mpPreview.Show();
}
}
catch
(Exception ex)
{
}
}
Thanks,
Jayesh Goyani
0

MadhuSudhan
Top achievements
Rank 1
answered on 24 May 2011, 07:28 AM
Hi Jayesh Goyani,
Thanks a lot Jayesh, It worked now................
Thanks a lot Jayesh, It worked now................