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

Custom Confirm Messages & Titles

12 Answers 503 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Joerg Schmidt
Top achievements
Rank 1
Joerg Schmidt asked on 10 Mar 2009, 02:49 AM

The confirm window feature has worked as required for us at the master level of the radgrid. We, were successfully able to set custom radwindow title and confirmation text in the ItemCreated method. However, the radwindow’s title doesn’t seem to appear in the child record even though it has been set in the ItemCreated method. Please see attached code.  I am not sure if this is a bug or code implementation issue.

 

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="ConfirmationLocalized._Default" %> 
 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
<!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></title>  
</head> 
<body> 
    <form id="form1" runat="server">  
    <div> 
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server">  
            <Scripts> 
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" /> 
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" /> 
                <asp:ScriptReference Path="~/jquery-telerik.js" /> 
            </Scripts> 
        </telerik:RadScriptManager> 
        <telerik:RadGrid ID="dtgShipper" runat="server" AutoGenerateColumns="False" GridLines="None" 
            OnDetailTableDataBind="dtgShipper_DetailTableDataBind" OnNeedDataSource="dtgShipper_NeedDataSource" 
            OnItemCommand="dtgShipper_ItemCommand" OnItemCreated="dtgShipper_ItemCreated">  
            <HeaderContextMenu> 
                <CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation> 
            </HeaderContextMenu> 
            <MasterTableView AllowPaging="True" DataKeyNames="id" PageSize="5" ShowHeader="False">  
                <DetailTables> 
                    <telerik:GridTableView runat="server" AllowPaging="True" PageSize="5" AutoGenerateColumns="False" 
                        ShowHeader="False">  
                        <RowIndicatorColumn> 
                            <HeaderStyle Width="20px"></HeaderStyle> 
                        </RowIndicatorColumn> 
                        <ExpandCollapseColumn> 
                            <HeaderStyle Width="20px"></HeaderStyle> 
                        </ExpandCollapseColumn> 
                        <Columns> 
                            <telerik:GridBoundColumn DataField="carriername" UniqueName="column1" ItemStyle-Width="85%">  
                                <ItemStyle Width="85%"></ItemStyle> 
                            </telerik:GridBoundColumn> 
                            <telerik:GridBoundColumn DataField="pieces" UniqueName="column2" ItemStyle-Width="85%">  
                                <ItemStyle Width="85%"></ItemStyle> 
                            </telerik:GridBoundColumn> 
                            <telerik:GridButtonColumn CommandArgument="Child" ConfirmDialogType="RadWindow" ButtonType="ImageButton" 
                                ItemStyle-Width="20" CommandName="Delete" Text="Delete" UniqueName="DeleteColumn" 
                                ConfirmText="Delete this record?" ConfirmTitle="Delete Confirm" ImageUrl="App_Themes/TEST/Images/delete.png">  
                                <ItemStyle Width="20px"></ItemStyle> 
                            </telerik:GridButtonColumn> 
                        </Columns> 
                    </telerik:GridTableView> 
                </DetailTables> 
                <RowIndicatorColumn> 
                    <HeaderStyle Width="20px"></HeaderStyle> 
                </RowIndicatorColumn> 
                <ExpandCollapseColumn Visible="True">  
                    <HeaderStyle Width="20px"></HeaderStyle> 
                </ExpandCollapseColumn> 
                <Columns> 
                    <telerik:GridBoundColumn DataField="shippername" UniqueName="column1">  
                    </telerik:GridBoundColumn> 
                    <telerik:GridButtonColumn CommandArgument="Child" ConfirmDialogType="RadWindow" ButtonType="ImageButton" 
                        ItemStyle-Width="20" CommandName="Delete" Text="Delete" UniqueName="DeleteColumnMaster" 
                        ConfirmText="Delete this shipper record?" ConfirmTitle="Delete Confirm" ImageUrl="App_Themes/TEST/Images/delete.png">  
                        <ItemStyle Width="20px"></ItemStyle> 
                    </telerik:GridButtonColumn> 
                </Columns> 
                <PagerStyle Mode="NumericPages" /> 
            </MasterTableView> 
            <FilterMenu EnableTheming="True">  
                <CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation> 
            </FilterMenu> 
        </telerik:RadGrid> 
    </div> 
    <telerik:RadWindowManager ID="RadWindowManager1" runat="server">  
    </telerik:RadWindowManager> 
    </form> 
</body> 
</html> 
 
using System;  
using System.Collections.Generic;  
using System.Linq;  
using System.Web;  
using System.Web.UI;  
using System.Web.UI.WebControls;  
using System.Data;  
using System.Data.Linq;  
using System.Data.Linq.Mapping;  
using System.Linq.Expressions;  
 
using Telerik.Web.UI;  
 
namespace ConfirmationLocalized  
{  
    public partial class _Default : System.Web.UI.Page  
    {  
 
        /// <summary>  
        /// Set page theme  
        /// </summary>  
        /// <param name="sender"></param>  
        /// <param name="e"></param>  
        void Page_PreInit(object sender, EventArgs e)  
        {  
            this.Page.Theme = "TEST";  
        }  
 
        protected void Page_Load(object sender, EventArgs e)  
        {  
 
        }  
 
        /// <summary>  
        /// Return shipper resultset  
        /// </summary>  
        /// <returns></returns>  
        private List<Table1> LoadShippers()  
        {  
            List<Table1> shipperResult = new List<Table1>();  
 
            Table1 shipper = new Table1();  
            shipper.ID = 1;  
            shipper.ShipperName = "ABC inc.";  
 
            shipperResult.Add(shipper);  
 
            shipper = new Table1();  
            shipper.ID = 2;  
            shipper.ShipperName = "ABC2 inc.";  
 
            shipperResult.Add(shipper);  
 
            return shipperResult;  
        }  
 
        /// <summary>  
        /// Returns pending shipment result set  
        /// </summary>  
        /// <returns></returns>  
        private List<Table2> LoadPendingData()  
        {  
            List<Table2> listResult = new List<Table2>();  
 
            Table2 itemResult = new Table2();  
 
            itemResult.carrierkey = 1;  
            itemResult.carriername = "A";  
            itemResult.pieces = 11;  
 
            listResult.Add(itemResult);  
 
            itemResult = new Table2();  
 
            itemResult.carrierkey = 2;  
            itemResult.carriername = "AA";  
            itemResult.pieces = 22;  
 
            listResult.Add(itemResult);  
 
            itemResult = new Table2();  
 
            itemResult.carrierkey = 3;  
            itemResult.carriername = "BAC";  
            itemResult.pieces = 33;  
 
            listResult.Add(itemResult);  
 
            return listResult;  
 
 
 
 
 
        }  
          
        /// <summary>  
        /// Loads shipper result set to grid  
        /// </summary>  
        /// <param name="source"></param>  
        /// <param name="e"></param>  
        protected void dtgShipper_NeedDataSource(object source, Telerik.Web.UI.GridNeedDataSourceEventArgs e)  
        {  
            this.dtgShipper.DataSource = this.LoadShippers();  
        }  
 
        /// <summary>  
        /// Loads child records for each shipper  
        /// </summary>  
        /// <param name="source"></param>  
        /// <param name="e"></param>  
        protected void dtgShipper_DetailTableDataBind(object source, Telerik.Web.UI.GridDetailTableDataBindEventArgs e)  
        {  
            GridDataItem parentItem = e.DetailTableView.ParentItem as GridDataItem;  
            e.DetailTableView.DataSource = this.LoadPendingData();  
            e.DetailTableView.DataMember = "Child";  
        }  
 
        protected void dtgShipper_ItemCommand(object source, GridCommandEventArgs e)  
        {  
 
        }  
 
        /// <summary>  
        /// Set custom confirm message and title  
        /// this could be used to set localized strings  
        /// </summary>  
        /// <param name="sender"></param>  
        /// <param name="e"></param>  
        protected void dtgShipper_ItemCreated(object sender, GridItemEventArgs e)  
        {  
 
              
            // Set Parent records custom message and title  
            foreach (GridColumn column in this.dtgShipper.MasterTableView.RenderColumns)  
            {  
                if (column is GridButtonColumn)  
                {  
                    if (column.UniqueName == "DeleteColumnMaster")  
                    {  
                        (column as GridButtonColumn).ConfirmText = "Delete this master record?";  
 
                        // Following title appears on the radwinow  
                        (column as GridButtonColumn).ConfirmTitle = "Delete master confirm";  
                    }  
                }  
            }  
 
            // Set chil records custom message and title  
            foreach (GridColumn column in this.dtgShipper.MasterTableView.DetailTables[0].RenderColumns)  
            {  
                if (column is GridButtonColumn)  
                {  
                    if (column.UniqueName == "DeleteColumn")  
                    {  
                        (column as GridButtonColumn).ConfirmText = "Delete this child record?";  
 
                         //Following title doesnt appear on the rad window  
                        (column as GridButtonColumn).ConfirmTitle = "Delete child confirm";  
                    }  
                }  
            }  
        }  
    }  
 
 
    /// <summary>  
    /// shipper table  
    /// </summary>  
    [Table(Name = "dbo.Table1")]  
    public partial class Table1  
    {  
        private int _id;  
        private string _shipperName;  
 
        public int ID {   
              
            get{return this._id ;}  
            set { this._id = value; }   
        }  
 
        public string ShipperName {  
            get { return this._shipperName; }  
            set { this._shipperName = value; }   
        }  
 
    }  
 
    /// <summary>  
    /// Pending shipment table  
    /// </summary>  
    [Table(Name = "dbo.Table2")]  
    public partial class Table2  
    {  
 
        private string _carriername;  
 
        private System.Nullable<int> _pieces;  
 
        private System.Nullable<double> _weight;  
 
        private int _carrierkey;  
 
        private string _unitid;  
 
        private System.Nullable<int> _shipperkey;  
 
        private System.Nullable<int> _companykey;  
 
        public Table2()  
        {  
        }  
 
        [Column(Storage = "_carriername", DbType = "NVarChar(50)")]  
        public string carriername  
        {  
            get 
            {  
                return this._carriername;  
            }  
            set 
            {  
                if ((this._carriername != value))  
                {  
                    this._carriername = value;  
                }  
            }  
        }  
 
        [Column(Storage = "_pieces", DbType = "Int")]  
        public System.Nullable<int> pieces  
        {  
            get 
            {  
                return this._pieces;  
            }  
            set 
            {  
                if ((this._pieces != value))  
                {  
                    this._pieces = value;  
                }  
            }  
        }  
 
        [Column(Storage = "_weight", DbType = "Float")]  
        public System.Nullable<double> weight  
        {  
            get 
            {  
                return this._weight;  
            }  
            set 
            {  
                if ((this._weight != value))  
                {  
                    this._weight = value;  
                }  
            }  
        }  
 
        [Column(Storage = "_carrierkey", DbType = "Int NOT NULL")]  
        public int carrierkey  
        {  
            get 
            {  
                return this._carrierkey;  
            }  
            set 
            {  
                if ((this._carrierkey != value))  
                {  
                    this._carrierkey = value;  
                }  
            }  
        }  
 
        [Column(Storage = "_unitid", DbType = "VarChar(25)")]  
        public string unitid  
        {  
            get 
            {  
                return this._unitid;  
            }  
            set 
            {  
                if ((this._unitid != value))  
                {  
                    this._unitid = value;  
                }  
            }  
        }  
 
        [Column(Storage = "_shipperkey", DbType = "Int")]  
        public System.Nullable<int> shipperkey  
        {  
            get 
            {  
                return this._shipperkey;  
            }  
            set 
            {  
                if ((this._shipperkey != value))  
                {  
                    this._shipperkey = value;  
                }  
            }  
        }  
 
        [Column(Storage = "_companykey", DbType = "Int")]  
        public System.Nullable<int> companykey  
        {  
            get 
            {  
                return this._companykey;  
            }  
            set 
            {  
                if ((this._companykey != value))  
                {  
                    this._companykey = value;  
                }  
            }  
        }  
    }  
}  
 

12 Answers, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 10 Mar 2009, 08:07 AM
Hi,

Can you try setting the ConfirmText and ConfirmTitle for the  GridButtonColumn in the PreRender event and see whether it is working.

CS:
protected void RadGrid1_PreRender(object sender, EventArgs e) 
    { 
        foreach (GridColumn column in RadGrid1.MasterTableView.DetailTables[0].RenderColumns) 
        { 
            if (column is GridButtonColumn) 
            { 
                if (column.UniqueName == "DeleteColumn"
                { 
                    (column as GridButtonColumn).ConfirmText = "Delete this child record?"
 
                    
                    (column as GridButtonColumn).ConfirmTitle = "Delete child confirm"
                } 
            } 
        } 
  }        


Thanks
Shinu



0
Joerg Schmidt
Top achievements
Rank 1
answered on 10 Mar 2009, 12:44 PM
Shinu,

Thank you for your response I treid the suggested code. However, the ConifrmText is being set but not the title.


protected void dtgShipper_PreRender(object sender, EventArgs e)  
        {  
            // Set chil records custom message and title  
            foreach (GridColumn column in this.dtgShipper.MasterTableView.DetailTables[0].RenderColumns)  
            {  
                if (column is GridButtonColumn)  
                {  
                    if (column.UniqueName == "DeleteColumn")  
                    {  
                        (column as GridButtonColumn).ConfirmText = "Delete this child record?";  
 
                        //Following title doesnt appear on the rad window  
                        (column as GridButtonColumn).ConfirmTitle = "Delete child confirm";  
                    }  
                }  
            }  
 
        } 
0
Iana Tsolova
Telerik team
answered on 12 Mar 2009, 01:02 PM
Hi Joerg,

What is the ConfirmDialogType of the corresponding ButtonColumn? The ConfirmTitle could be changed only of you are using RadWindow as ConfirmDialogType.

All the best,
Iana
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Joerg Schmidt
Top achievements
Rank 1
answered on 12 Mar 2009, 01:27 PM

Lana,

The gridbuttoncolum's ConfirmDialogType is set to RadWindow. The title does show up for the parent record but not child(detail) level when set from Code Behind. Please review view post for Markup and code behind. Its included in the original post.



<telerik:GridButtonColumn CommandArgument="Child" ConfirmDialogType="RadWindow" ButtonType="ImageButton" 
                        ItemStyle-Width="20" CommandName="Delete" Text="Delete" UniqueName="DeleteColumnMaster" 
                        ConfirmText="Delete this shipper record?" ConfirmTitle="Delete Confirm" ImageUrl="App_Themes/TEST/Images/delete.png">  
                        <ItemStyle Width="20px"></ItemStyle> 
                    </telerik:GridButtonColumn> 
0
Iana Tsolova
Telerik team
answered on 13 Mar 2009, 03:51 PM
Hi Joerg,

Thank you for providing additional information on this.
I tested it further and was able to replicate it on my side. I will forward the issue to our developers and hope solution could be easily found.
Please excuse us for the inconvenience.

Regards,
Iana
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Emerson
Top achievements
Rank 1
answered on 31 May 2013, 08:38 PM
Was this ever solved? I have the same problem. The confirm box opens and all info is set except the title shows "The page at localhost says:".

<telerik:GridButtonColumn ConfirmText="Delete this address?" ConfirmDialogType="RadWindow"
                                                                  ConfirmTitle="Delete" ButtonType="ImageButton" CommandName="Delete" Text="Delete"
                                                                  UniqueName="DeleteColumn">
                                        <ItemStyle HorizontalAlign="Center" CssClass="RadGridDeleteImageButton"></ItemStyle>
                                        </telerik:GridButtonColumn>
0
Angel Petrov
Telerik team
answered on 05 Jun 2013, 12:25 PM
Hi Emerson,

You should not experience such behavior. Could you ensure that you have included a RadWindowManager on the page? Also please note that the last post in this thread was from 2009.

Regards,
Angel Petrov
Telerik
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.
0
Emerson
Top achievements
Rank 1
answered on 11 Jun 2013, 08:43 PM
Yes I have a RadWindowManager on the page. I am attaching an image showing what it looks like.
0
Angel Petrov
Telerik team
answered on 14 Jun 2013, 04:01 PM
Hello Emerson,

As I see form the image provided you have a page which is loaded in a RadWindow and in that page the grid is placed. Could you ensure that the RadWindowManager is placed in the page where the grid is located? I tried reproducing the problem described in a sample project but to no avail. As you can see from the attached website(please run Default2.aspx) the message is displayed as expected. Am I missing something? Are there any differences between my test project and your application?

Regards,
Angel Petrov
Telerik
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 the blog feed now.
0
Emerson
Top achievements
Rank 1
answered on 19 Jun 2013, 01:26 AM
Yes it is on the same page as the grid. This is what I have on that form.

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="TaskCosts.aspx.cs" Inherits="TaskCore.TaskCosts" %>
 
<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head runat="server">
    <title></title>
    <link href="Styles/Site.css" rel="stylesheet" type="text/css" />
 
    <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
        <script type="text/javascript">
            function GetRadWindow() {
                var oWindow = null;
                if (window.radWindow)
                    oWindow = window.RadWindow; //Will work in Moz in all cases, including clasic dialog    
                else if (window.frameElement.radWindow)
                    oWindow = window.frameElement.radWindow; //IE (and Moz as well)    
                return oWindow;
            }
            function Close() {
                GetRadWindow().Close();
                // call function on parent
                GetRadWindow().BrowserWindow.CalledFn();
            }
            function CloseOnly() {
                GetRadWindow().Close();
            }
            // CallFnOnParent shows how to call a function
            // in the parent page. A javascript function named CalledFn
            // must exist in the parent page.
            function CallFnOnParent() {
                GetRadWindow().BrowserWindow.CalledFn();
            }
 
            // CallFn illustrates how to call a function in one RadWindow
            // from another.
            function CallFn() {
                //Get a reference to the parent page
                var oWnd = GetRadWindow();
                //get a reference to the second RadWindow      
                var dialogB = oWnd.get_windowManager().getWindowByName("RadWindow1");
                // by using get_contentFrame, call the predefined function
                dialogB.get_contentFrame().contentWindow.CalledFn();
            }
 
            // RadGrid Client Side functions
            var RadGrid1;
 
            function GetGridObject(sender, eventArgs) {
                RadGrid1 = sender;
            }
            function ResizeColumn(index, width) {
                var columnCount = RadGridMain.get_masterTableView().get_columns().length - 1;
                if (index < 0 || index > columnCount) {
                    alert("Invalid index! The valid range is: " + 0 + "-" + columnCount);
                }
                else {
                    RadGridMain.get_masterTableView().resizeColumn(index, width);
                }
            }
 
            function RequestStart(sender, args) {
                if (args.get_eventArgument().indexOf("Export") != -1) {
                    args.set_enableAjax(false);
                }
            }
            function SelectRow(sender, args) {
                var grid = $find("<%=RadGridMain.ClientID %>");
                var MasterTable = grid.get_masterTableView();
                var selectedRows = MasterTable.get_selectedItems();
                var row = selectedRows[0];
            }
 
        </script>
    </telerik:RadCodeBlock>
</head>
<body>
    <form id="form1" runat="server">
    <div id="StdLevel1" class="StdLevel1">
        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        </telerik:RadAjaxManager>
        <telerik:RadScriptManager ID="ScriptManager1" runat="server" EnableTheming="True">
            <Scripts>
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js">
                </asp:ScriptReference>
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js">
                </asp:ScriptReference>
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js">
                </asp:ScriptReference>
            </Scripts>
        </telerik:RadScriptManager>
         
            <div class="EditFormTitle">
                <asp:Label ID="lblFormTitle" runat="server" Text="Task Costs"></asp:Label>
            </div>
            <table id="Table1" runat="server" style="width:100%;">
                <tr>
                    <td class="EditFormLabel">
                        <asp:Label ID="Label5" runat="server" Text="Task" />:
                        <asp:Label ID="lblProject" runat="server" Text="Project Code" />
                    </td>
                </tr>
                <tr>
                    <td>
                        <telerik:RadAjaxManager ID="RadAjaxManager2" runat="server">
                            <AjaxSettings>
                                <telerik:AjaxSetting AjaxControlID="RadGrid1">
                                    <UpdatedControls>
                                        <telerik:AjaxUpdatedControl ControlID="RadGridMain" LoadingPanelID="RadAjaxLoadingPanelMain">
                                        </telerik:AjaxUpdatedControl>
                                        <telerik:AjaxUpdatedControl ControlID="RadWindowManagerMain"></telerik:AjaxUpdatedControl>
                                    </UpdatedControls>
                                </telerik:AjaxSetting>
                            </AjaxSettings>
                            <ClientEvents OnRequestStart="RequestStart"></ClientEvents>
                        </telerik:RadAjaxManager>
                        <telerik:RadAjaxPanel ID="RAjax" runat="server">
                            <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanelMain" runat="server">
                            </telerik:RadAjaxLoadingPanel>
                             
                            <telerik:RadGrid ID="RadGridMain" runat="server"
                                AutoGenerateEditColumn="True" CellSpacing="0" DataSourceID="ldsMain" GridLines="None"
                                AutoGenerateColumns="False" AllowPaging="True" PageSize="5" OnUpdateCommand="RadGridMain_UpdateCommand"
                                OnDeleteCommand="RadGridMain_DeleteCommand" OnInsertCommand="RadGridMain_InsertCommand"
                                 Width="100%" Height="100%" OnPreRender="RadGridMain_PreRender" >
                                <PagerStyle Mode="NextPrevAndNumeric" AlwaysVisible="True"></PagerStyle>
                                <MasterTableView DataSourceID="ldsMain" Name="ProjectUsersView" CommandItemDisplay="Top" DataKeyNames="TaskCostID">
                                    <CommandItemSettings ExportToPdfText="Export to PDF"></CommandItemSettings>
                                    <RowIndicatorColumn Visible="True" FilterControlAltText="Filter RowIndicator column">
                                    </RowIndicatorColumn>
                                    <ExpandCollapseColumn Visible="True" FilterControlAltText="Filter ExpandColumn column">
                                    </ExpandCollapseColumn>
                                    <Columns>
                                     <telerik:GridBoundColumn DataField="TaskCostID" FilterControlAltText="Filter TaskCostID column"
                                            HeaderText="TaskCostID" UniqueName="TaskCostID"
                                            SortExpression="TaskCostID" ReadOnly="true" DataType="System.Int32" Visible="false" >
                                        </telerik:GridBoundColumn>
                                     
                                        <telerik:GridDropDownColumn DataField="CostCodeID" DataSourceID="ldsCostCodes" HeaderText="Cost Code"
                                            ListTextField="CostCodeName" ListValueField="CostCodeID" UniqueName="CostCodeID" ColumnEditorID="GridDropDownColumnEditor1"
                                            DropDownControlType="DropDownList">
                                            </telerik:GridDropDownColumn>
                                        <telerik:GridNumericColumn DataField="AmountCost" DataType="System.Decimal" NumericType="Currency"
                                            FilterControlAltText="Filter AmountCost column" HeaderText="Amount"
                                            SortExpression="AmountCost" UniqueName="AmountCost" DecimalDigits="2" DefaultInsertValue="0.00">
                                        </telerik:GridNumericColumn>
                                        <telerik:GridDateTimeColumn DataField="TSCost" DataType="System.DateTime"
                                            FilterControlAltText="Filter TSCost column" HeaderText="Time" PickerType="DateTimePicker"
                                            DataFormatString="{0:MM/dd/yyyy}" SortExpression="TSCost" UniqueName="TSCost">
                                        </telerik:GridDateTimeColumn>
                                        
                                        <telerik:GridBoundColumn DataField="Description"
                                            FilterControlAltText="Filter Description column" HeaderText="Description"
                                            SortExpression="Description" UniqueName="Description">
                                        </telerik:GridBoundColumn>
                                        <telerik:GridButtonColumn ConfirmText="Delete this Cost?" ConfirmDialogType="RadWindow"
                                                                  ConfirmTitle="Delete" ButtonType="ImageButton" CommandName="Delete" Text="Delete"
                                                                  UniqueName="DeleteColumn">
                                        <ItemStyle HorizontalAlign="Center" CssClass="RadGridDeleteImageButton"></ItemStyle>
                                        </telerik:GridButtonColumn>
                                    </Columns>
                                    <EditFormSettings>
                                        <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                                        </EditColumn>
                                    </EditFormSettings>
                                    <PagerStyle AlwaysVisible="True" />
                                </MasterTableView>
                                <FilterMenu EnableImageSprites="False">
                                </FilterMenu>
                                <ClientSettings>
                                    <Resizing EnableRealTimeResize="True" ResizeGridOnColumnResize="False" AllowColumnResize="true"
                                        ClipCellContentOnResize="false"></Resizing>
                                    <Selecting AllowRowSelect="True" />
                                </ClientSettings>
                                <ExportSettings IgnorePaging="True" FileName="OCore-Export" OpenInNewWindow="True">
                                    <Pdf Author="OCore" Creator="OCore" PaperSize="letter" PageTitle="Project Users"
                                        Title="ProjectUsers" Subject="test subject" />
                                </ExportSettings>
                            </telerik:RadGrid>
                            <telerik:GridDropDownListColumnEditor ID="GridDropDownColumnEditor1" runat="server"
                                DropDownStyle-Width="110px">
                            </telerik:GridDropDownListColumnEditor>
                            <telerik:GridDropDownListColumnEditor ID="GridDropDownListColumnEditor2" runat="server"
                                DropDownStyle-Width="110px">
                            </telerik:GridDropDownListColumnEditor>
                           
                        </telerik:RadAjaxPanel>
                    </td>
                </tr>
                <tr>
                    <td>
                        <asp:Button ID="btnExportXLS" runat="server" CssClass="StdButtonExportXLS" OnClick="btnExportXLS_Click" />
                        <asp:Button ID="btnExportPDF" runat="server" CssClass="StdButtonExportPDF" OnClick="btnExportPDF_Click" />
                        <asp:Button ID="btnDone" runat="server" CssClass="StdButtonDone" OnClick="btnDone_Click"
                            CausesValidation="false" />
                        <asp:Label ID="lblScript" runat="server" Text=" " />
                    </td>
                </tr>
                <tr>
                    <td>
                    </td>
                </tr>
                <tr>
                    <td>
                        <asp:ValidationSummary ID="ValidationSummary1" runat="server" ValidationGroup="ServerSide" />
                    </td>
                </tr>
            </table>
            <%-- ews debug hook up this validation --%>
            <asp:CustomValidator ID="cvProjectUserUnique" runat="server" ErrorMessage="Project User already exists."
                ValidationGroup="ServerSide" Visible="false"></asp:CustomValidator><br />
        
    </div>
    </form>
    <telerik:RadWindowManager ID="RadWindowManagerMain" runat="server">
    </telerik:RadWindowManager>
    <asp:LinqDataSource ID="ldsMain" runat="server" ContextTypeName="TaskCore.tbleTasksDataContext"
        EntityTypeName="" TableName="TaskCosts" OrderBy="TaskCostID"       
        Select="new (TaskCostID, CostCodeID, AmountCost, Description, TSEntered, EnteredBy, TSCost)">
    </asp:LinqDataSource>
    <asp:LinqDataSource ID="ldsCostCodes" runat="server" ContextTypeName="TaskCore.tbleSettingsDataContext"
        EntityTypeName="" TableName="CostCodes" OrderBy="CostCodeName"
        Select="new (CostCodeID, CostCodeName)">
    </asp:LinqDataSource>
 
    <script type="text/javascript">
        $(window).on('load resize', function () {
            vpw = $(window).width();
            vph = $(window).height();
            $('#StdLevel1').css({ 'height': vph + 'px' });
            $('#StdLevel1').css({ 'width': vpw - 20 + 'px' });
            $('#StdLevel1').css({ 'overflow': 'auto' });
        }).resize();
    </script>
     
</body>
</html>
0
Angel Petrov
Telerik team
answered on 21 Jun 2013, 03:47 PM
Hi Emerson,

There are two things which might be causing the problem:
  1. There are controls on the page ajaxified by both a RadAjaxManager and RadAjaxPanel. Now this will break the functionality as nested update panels will create which is an unsupported scenario by the framework. More about this issue you can find in this help article.
  2. The RadWindowManager's declaration is placed outside the form tag while it should have been placed inside it.

By modifying the logic accordingly you should be able to resolve the problem.

Regards,
Angel Petrov
Telerik
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 the blog feed now.
0
Emerson
Top achievements
Rank 1
answered on 27 Jun 2013, 04:42 AM
The RadWindowManager outside of the form was the problem. I also went ahead and fixed the RadAjaxPanel so it would not cause issues. Thanks for the help.
Tags
Grid
Asked by
Joerg Schmidt
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Joerg Schmidt
Top achievements
Rank 1
Iana Tsolova
Telerik team
Emerson
Top achievements
Rank 1
Angel Petrov
Telerik team
Share this question
or