Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
101 views
Hello.
I use RadWindowManager to display alert windows.
I have code like this:

<telerik:RadWindowManager ID="window1" runat="server" ReloadOnShow="true"
EnableEmbeddedBaseStylesheet="false" EnableEmbeddedSkins="false" OnClientClose="javascript:alert('test')">
...
</telerik:RadWindowManager>

The problem is when I use this code without "OnClientClose" it works fine but whei I add "OnClientClose"
the alert is not displayed

Thanks.
Svetlina Anati
Telerik team
 answered on 15 Feb 2011
2 answers
125 views
I have a grid that has two sets of columns. I want to hide or show (i.e. Display=false) one set based on the value of a droplist (which has only two possible values) during execution using client-side script. The problem I'm having is that the value of the cellIndex (i.e. element.cellIndex) for the hidden columns has the same value for each of the columns in the second set (which initially have Display="false" set, since they are to be hidden initially). I originally tried using element.uniqueNumber, but this value changes dynamically (Note: This does work initially). I found other posts that suggested using element.cellIndex instead, so hence my efforts here. FWIW, I am also using jQuery 1.4.4 in addition to the Ajax supported intrinsically by the Telerik controls.

Here is the JS I use to Toggle the columns (called when the droplist changes):

var actualColNames = "ActualTotalStaff", "ActualProgramTeam", "ActualSupportTeam"];
var projColNames = ["ProjectedTotalStaff", "ProjectedProgramTeam", "ProjectedSupportTeam"];
  
//  This function toggles the display of Actual and Projected columns in the grid based on the
//  selection in the Summary droplist.
function ToggleColumns()
{
    var masterTable = null;
    var selection = "";
    var cols = [];
    var numColumns = 0;
    var element = null;
    var nameIndex = -1;
    var colIndex = -1;
    var colName = ""
    var displayIndex =-1
    var isActual = false;
    var isProjected = false;
      
    // Droplist value: Actual or Projected
    selection = $('option:selected')[0].text;
    masterTable = $find('<%=RadGrid_StaffBreakout.ClientID %>').get_masterTableView();
      
    if (masterTable)
    {
        isActual = (selection == "Actual");
        isProjected = !isActual;
        cols = masterTable.get_columns();
        numColumns = cols.length;
  
        $(cols).each(function()
        {
            element = this.get_element();
            colIndex = element.cellIndex;    //this._element.uniqueNumber;
            colName = this._data.UniqueName;
  
            //  Find this column name in the Projected column name array.
            nameIndex = $.inArray(colName, projColNames);
  
            if ((nameIndex > -1) && (colIndex <= numColumns))
            {
                //  If Actual is selected, then hide this Projected column.
                (isActual ? masterTable.hideColumn(colIndex) : masterTable.showColumn(colIndex));
            }
            else
            {
                //  Find this column name in the Actual column name array.
                nameIndex = $.inArray(colName, actualColNames);
  
                if ((nameIndex > -1) && (colIndex <= numColumns))
                {
                    //  If Projected is selected, then hide this Actual column.
                    (isProjected ? masterTable.hideColumn(colIndex) : masterTable.showColumn(colIndex));
                }
            }
        });
    }
}

Apologies, but the grid markup is quite lengthy. The Actual set works fine for showing/hiding, it's the Projected set that doesn't work properly.

<telerik:radgrid id="RadGrid_StaffBreakout" runat="server" 
    autogeneratecolumns="False" allowsorting="True" gridlines="None" 
    insertitempageindexaction="ShowItemOnFirstPage" 
   allowpaging="True" skin="Windows7" horizontalalign="Center">
    <ClientSettings ClientEvents-OnMasterTableViewCreated="OnMasterTableViewCreatedHandler"
        Resizing-AllowColumnResize="true" ClientEvents-OnCommand="OnCommandHandler" EnableRowHoverStyle="true">
        <ClientEvents OnMasterTableViewCreated="OnMasterTableViewCreatedHandler" OnCommand="OnCommandHandler"></ClientEvents>
        <Resizing AllowColumnResize="True"></Resizing>
    </ClientSettings>
    <ItemStyle HorizontalAlign="Center" BorderWidth="0px" />
    <MasterTableView HorizontalAlign="Center" GridLines="None" EditMode="InPlace" CommandItemDisplay="TopAndBottom" >
        <SortExpressions>
            <telerik:GridSortExpression FieldName="ScheduleDate" SortOrder="Descending" />
        </SortExpressions>
        <CommandItemSettings ExportToPdfText="Export to Pdf"
            ShowExportToExcelButton="True" ShowExportToPdfButton="True">
        </CommandItemSettings>           
        <Columns>
            <telerik:GridBoundColumn DataField="StaffBreakoutId" DataType="System.Int32" 
                ShowFilterIcon="False" SortExpression="StaffBreakoutId" 
                UniqueName="StaffBreakoutId" Visible="False">                
            </telerik:GridBoundColumn>
            <telerik:GridEditCommandColumn>
                <HeaderStyle Width="90px" />
            </telerik:GridEditCommandColumn>
            <telerik:GridTemplateColumn DataField="ScheduleDate" HeaderButtonType="None" 
                HeaderText="Day" SortExpression="ScheduleDate" UniqueName="ScheduleDate">
                <HeaderStyle Width="125px" />
                <EditItemTemplate>
                    <telerik:RadDatePicker ID="RadDatePicker_ScheduleDate" UniqueName="RadDatePicker_ScheduleDate" runat="server"
                        DbSelectedDate= '<%# Bind("ScheduleDate") %>' Width="125px"
                        Skin="Outlook">
                    </telerik:RadDatePicker>
                    <span style="color:Red;"><asp:RequiredFieldValidator ID="RequiredFieldValidator_ScheduleDate" runat="server" errormessage="*" ControlToValidate="RadDatePicker_ScheduleDate"></asp:RequiredFieldValidator></span>
                </EditItemTemplate>
                <ItemTemplate>
                    <asp:Label ID="ScheduleDateLabel" runat="server" 
                        Text='<%# Eval("ScheduleDate", "{0:d}") %>'></asp:Label>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn UniqueName="ActualTotalStaff" SortExpression="ActualTotalStaffBI"  InitializeTemplatesFirst="false">
                <HeaderStyle Width="105px" />
                <HeaderTemplate>
                    <table id="totalStaffHeader" cellpadding="1" cellspacing="1" width="100%" style="text-align:center;">
                        <tr>
                            <td colspan="2"><b>TOTAL STAFF</b></td>
                        </tr>
                        <tr></tr>
                        <tr>
                            <td style="width:50%;">BI</td>
                            <td style="width:50%;">DE</td>
                        </tr>
                    </table>
                </HeaderTemplate>
                <EditItemTemplate>
                    <table id="actualStaffTableEdit" cellpadding="1" cellspacing="1" width="100%">
                        <tr>
                            <td style="width:50%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualTotalStaffBI" runat="server" 
                                    DbValue='<%# Bind("ActualTotalStaffBI", "{0:n1}") %>' Width="30px">
                                </telerik:RadNumericTextBox>
                                <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ActualTotalStaffBI" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualTotalStaffBI">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width:50%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualTotalStaffDE" runat="server" DbValue='<%# Bind("ActualTotalStaffDE", "{0:n1}") %>'
                                    Width="30px"></telerik:RadNumericTextBox>
                                <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ActualTotalStaffDE" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualTotalStaffDE">
                                </asp:RequiredFieldValidator></span>
                            </td>
                        </tr>
                    </table>
                </EditItemTemplate>
                <ItemTemplate>
                    <table id="totalStaffItem" cellpadding="1" cellspacing="1" width="100%" style="text-align:center;">
                        <tr>
                            <td style="width: 50%; border-bottom: none;"><%#DataBinder.Eval(Container.DataItem, "ActualTotalStaffBI", "{0:n1}")%></td>
                            <td style="width:50%; border-bottom: none;" ><%#DataBinder.Eval(Container.DataItem, "ActualTotalStaffDE", "{0:n1}")%></td>
                        </tr>
                    </table>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn UniqueName="ActualProgramTeam" InitializeTemplatesFirst="false"
                SortExpression="ActualProgramTeamBI">
                <HeaderStyle Width="105px" />
                <HeaderTemplate>
                    <table id="actualProgramTeamHeader" cellpadding="1" cellspacing="1" width="100%"
                        style="text-align: center;">
                        <tr>
                            <td colspan="2"><b>PROGRAM TEAM</b></td>
                        </tr>
                        <tr>
                            <td colspan="2"><b>ROCKVILLE</b></td>
                        </tr>
                        <tr>
                            <td style="width:50%;">BI</td>
                            <td style="width:50%;">DE</td>
                        </tr>
                    </table>
                </HeaderTemplate>
                <EditItemTemplate>
                    <table id"actualProgramTeamEdit" cellpadding="1" cellspacing="1" width="100%">
                        <tr>
                            <td style="width:50%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualProgramTeamBI" runat="server" DbValue='<%# Bind("ActualProgramTeamBI", "{0:n1}") %>'
                                    Width="30px"></telerik:RadNumericTextBox>
                                <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ActualProgramTeamBI" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualProgramTeamBI">
                                </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width:50%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualProgramTeamDE" runat="server" DbValue='<%# Bind("ActualProgramTeamDE", "{0:n1}") %>' Width="30px"></telerik:RadNumericTextBox>
                                <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ActualProgramTeamDE" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualProgramTeamDE">
                                </asp:RequiredFieldValidator></span>
                            </td>
                        </tr>
                    </table>
                </EditItemTemplate>
                <ItemTemplate>
                    <table id="totalStaffItem" cellpadding="1" cellspacing="1" width="100%" style="text-align: center;">
                        <tr>
                            <td style="width: 50%; border-bottom: none;">
                                <%#DataBinder.Eval(Container.DataItem, "ActualProgramTeamBI", "{0:n1}")%>
                            </td>
                            <td style="width: 50%; border-bottom: none;">
                                <%#DataBinder.Eval(Container.DataItem, "ActualProgramTeamDE", "{0:n1}")%>
                            </td>
                        </tr>
                    </table>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn  UniqueName="ActualSupportTeam" InitializeTemplatesFirst="false" 
                SortExpression="ActualBISupportTeamRI">
                <HeaderStyle Width="380px" />
                <HeaderTemplate>
                    <table id="supportTeamsHeader" cellpadding="1" cellspacing="1" width="100%" style="text-align: center;">
                        <tr>
                            <td colspan="7" align="center">
                                <b>SUPPORT TEAMS</b>
                            </td>
                        </tr>
                        <tr style="text-align:center;">
                            <td style="width: 14%;"><b>RI</b></td>
                            <td style="width: 14%;"><b>TX</b></td>
                            <td style="width: 14%;"><b>MD</b></td>
                            <td style="width: 14%;"><b>RI</b></td>
                            <td style="width: 14%;"><b>TX</b></td>
                            <td style="width: 14%;"><b>MD</b></td>
                            <td style="width: 16%;"><b>TOTAL</b></td>
                       </tr>
                        <tr>
                            <td style="width: 14%;">BI</td>
                            <td style="width: 14%;">BI</td>
                            <td style="width: 14%;">BI</td>
                            <td style="width: 14%;">DE</td>
                            <td style="width: 14%;">DE</td>
                            <td style="width: 14%;">DE</td>
                            <td style="width: 16%;">     </td>
                        </tr>
                    </table>
                </HeaderTemplate>
                <EditItemTemplate>
                    <table id="supportTeamsEdit" cellpadding="1" cellspacing="1" width="100%">
                        <tr>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualBISupportTeamRI" runat="server" DbValue='<%# Bind("ActualBISupportTeamRI", "{0:n1}") %>'
                                    Width="30px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ActualBISupportTeamRI" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualBISupportTeamRI">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualBISupportTeamTX" runat="server" DbValue='<%# Bind("ActualBISupportTeamTX", "{0:n1}") %>'
                                    Width="30px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ActualBISupportTeamTX" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualBISupportTeamTX">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualBISupportTeamMD" runat="server" DbValue='<%# Bind("ActualBISupportTeamMD", "{0:n1}") %>'
                                    Width="30px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ActualBISupportTeamMD" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualBISupportTeamMD">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualDESupportTeamRI" runat="server" DbValue='<%# Bind("ActualDESupportTeamRI", "{0:n1}") %>'
                                    Width="30px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ActualDESupportTeamRI" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualDESupportTeamRI">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualDESupportTeamTX" runat="server" DbValue='<%# Bind("ActualDESupportTeamTX", "{0:n1}") %>'
                                    Width="30px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ActualDESupportTeamTX" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualDESupportTeamTX">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualDESupportTeamMD" runat="server" DbValue='<%# Bind("ActualDESupportTeamMD", "{0:n1}") %>'
                                    Width="30px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ActualDESupportTeamMD" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualDESupportTeamMD">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 16%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ActualSupportTeamTotal" runat="server" DbValue='<%# Bind("ActualSupportTeamTotal", "{0:n1}") %>'
                                    Width="30px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ActualSupportTeamTotal" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ActualSupportTeamTotal">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                        </tr>
                    </table>
                </EditItemTemplate>
                <ItemTemplate>
                    <table id="supportTeamsItem" cellpadding="1" cellspacing="1" width="100%" style="text-align: center;">
                        <tr>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ActualBISupportTeamRI", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ActualBISupportTeamTX", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ActualBISupportTeamMD", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ActualDESupportTeamRI", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ActualDESupportTeamTX", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ActualDESupportTeamMD", "{0:n1}")%></td>
                            <td style="width: 16%; border-bottom: none;"><%#Eval("ActualSupportTeamTotal", "{0:n1}")%></td>
                        </tr>
                    </table>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn UniqueName="ProjectedTotalStaff" SortExpression="ProjectedTotalStaffBI" InitializeTemplatesFirst="false" Display="false">
                <HeaderStyle Width="105px" />
                <HeaderTemplate>
                    <table id="projectedTotalStaffHeader" cellpadding="1" cellspacing="1" width="100%" style="text-align:center;">
                        <tr>
                            <td colspan="2"><b>TOTAL STAFF</b></td>
                        </tr>
                        <tr></tr>
                        <tr>
                            <td style="width:50%;">BI</td>
                            <td style="width:50%;">DE</td>
                        </tr>
                    </table>
                </HeaderTemplate>
                <EditItemTemplate>
                    <table id="projectedTotalStaffEdit" cellpadding="1" cellspacing="1" width="100%">
                        <tr>
                            <td style="width:50%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedTotalStaffBI" runat="server" 
                                    DbValue='<%# Bind("ProjectedTotalStaffBI", "{0:n1}") %>' Width="30px">
                                </telerik:RadNumericTextBox>
                                <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedTotalStaffBI" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedTotalStaffBI">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width:50%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedTotalStaffDE" runat="server" DbValue='<%# Bind("ProjectedTotalStaffDE", "{0:n1}") %>'
                                    Width="30px"></telerik:RadNumericTextBox>
                                <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedTotalStaffDE" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedTotalStaffDE">
                                </asp:RequiredFieldValidator></span>
                            </td>
                        </tr>
                    </table>
                </EditItemTemplate>
                <HeaderStyle Width="50px" />
                <ItemTemplate>
                    <table id="projectedTotalStaffItem" cellpadding="1" cellspacing="1" width="100%" style="text-align:center;">
                        <tr>
                            <td style="width: 50%; border-bottom: none;"><%#DataBinder.Eval(Container.DataItem, "ProjectedTotalStaffBI", "{0:n1}")%></td>
                            <td style="width:50%; border-bottom: none;" ><%#DataBinder.Eval(Container.DataItem, "ProjectedTotalStaffDE", "{0:n1}")%></td>
                        </tr>
                    </table>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn UniqueName="ProjectedProgramTeam" Display="false" SortExpression="ProjectedProgramTeamBI" InitializeTemplatesFirst="false">
                <HeaderStyle Width="120px" />
                <HeaderTemplate>
                    <table id="projectedProgramTeamHeader" cellpadding="1" cellspacing="1" width="100%"
                        style="text-align: center;">
                        <tr>
                            <td colspan="2"><b>PROGRAM TEAM</b></td>
                        </tr>
                        <tr>
                            <td colspan="2"><b>ROCKVILLE</b></td>
                        </tr>
                        <tr>
                            <td style="width:50%;">BI</td>
                            <td style="width:50%;">DE</td>
                        </tr>
                    </table>
                </HeaderTemplate>
                <EditItemTemplate>
                    <table id"projectedProgramTeamEdit" cellpadding="1" cellspacing="1" width="100%">
                        <tr>
                            <td style="width:50%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedProgramTeamBI" runat="server" DbValue='<%# Bind("ProjectedProgramTeamBI", "{0:n1}") %>'
                                    Width="30px"></telerik:RadNumericTextBox>
                                <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedProgramTeamBI" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedProgramTeamBI">
                                </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width:50%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedProgramTeamDE" runat="server" DbValue='<%# Bind("ProjectedProgramTeamDE", "{0:n1}") %>' Width="30px"></telerik:RadNumericTextBox>
                                <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedProgramTeamDE" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedProgramTeamDE">
                                </asp:RequiredFieldValidator></span>
                            </td>
                        </tr>
                    </table>
                </EditItemTemplate>
                <ItemTemplate>
                    <table id="projectedProgramTeamItem" cellpadding="1" cellspacing="1" width="100%" style="text-align: center;">
                        <tr>
                            <td style="width: 50%; border-bottom: none;">
                                <%#DataBinder.Eval(Container.DataItem, "ProjectedProgramTeamBI", "{0:n1}")%>
                            </td>
                            <td style="width: 50%; border-bottom: none;">
                                <%#DataBinder.Eval(Container.DataItem, "ProjectedProgramTeamDE", "{0:n1}")%>
                            </td>
                        </tr>
                    </table>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn UniqueName="ProjectedSupportTeam" Display="false" SortExpression="ProjectedBISupportTeamRI" InitializeTemplatesFirst="false">
                <HeaderStyle Width="380px" />
                <HeaderTemplate>
                    <table id="projectedSupportTeamHeader" cellpadding="1" cellspacing="1" width="100%" style="text-align: center;">
                        <tr>
                            <td colspan="7" align="center">
                                <b>SUPPORT TEAMS</b>
                            </td>
                        </tr>
                        <tr style="text-align:center;">
                            <td style="width: 14%;"><b>RI</b></td>
                            <td style="width: 14%;"><b>TX</b></td>
                            <td style="width: 14%;"><b>MD</b></td>
                            <td style="width: 14%;"><b>RI</b></td>
                            <td style="width: 14%;"><b>TX</b></td>
                            <td style="width: 14%;"><b>MD</b></td>
                            <td style="width: 16%;"><b>TOTAL</b></td>
                       </tr>
                        <tr>
                            <td style="width: 14%;">BI</td>
                            <td style="width: 14%;">BI</td>
                            <td style="width: 14%;">BI</td>
                            <td style="width: 14%;">DE</td>
                            <td style="width: 14%;">DE</td>
                            <td style="width: 14%;">DE</td>
                            <td style="width: 16%;">     </td>
                        </tr>
                    </table>
                </HeaderTemplate>
                <EditItemTemplate>
                    <table id="projectedSupportTeamEdit" cellpadding="1" cellspacing="1" width="100%">
                        <tr>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedBISupportTeamRI" runat="server" DbValue='<%# Bind("ProjectedBISupportTeamRI", "{0:n1}") %>'
                                    Width="29px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedBISupportTeamRI" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedBISupportTeamRI">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedBISupportTeamTX" runat="server" DbValue='<%# Bind("ProjectedBISupportTeamTX", "{0:n1}") %>'
                                    Width="29px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedBISupportTeamTX" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedBISupportTeamTX">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedBISupportTeamMD" runat="server" DbValue='<%# Bind("ProjectedBISupportTeamMD", "{0:n1}") %>'
                                    Width="29px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedBISupportTeamMD" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedBISupportTeamMD">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedDESupportTeamRI" runat="server" DbValue='<%# Bind("ProjectedDESupportTeamRI", "{0:n1}") %>'
                                    Width="29px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedDESupportTeamRI" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedDESupportTeamRI">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedDESupportTeamTX" runat="server" DbValue='<%# Bind("ProjectedDESupportTeamTX", "{0:n1}") %>'
                                    Width="29px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedDESupportTeamTX" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedDESupportTeamTX">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 14%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedDESupportTeamMD" runat="server" DbValue='<%# Bind("ProjectedDESupportTeamMD", "{0:n1}") %>'
                                    Width="29px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedDESupportTeamMD" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedDESupportTeamMD">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                            <td style="width: 16%; border-bottom: none;">
                                <telerik:RadNumericTextBox ID="TextBox_ProjectedSupportTeamTotal" runat="server" DbValue='<%# Bind("ProjectedSupportTeamTotal", "{0:n1}") %>'
                                    Width="36px">
                                </telerik:RadNumericTextBox>
                                <span style="color: Red;">
                                    <asp:RequiredFieldValidator id="RequiredFieldValidator_ProjectedSupportTeamTotal" runat="server"
                                        errormessage="*" controltovalidate="TextBox_ProjectedSupportTeamTotal">
                                    </asp:RequiredFieldValidator></span>
                            </td>
                        </tr>
                    </table>
                </EditItemTemplate>
                <ItemTemplate>
                    <table id="projectedSupportTeamItem" cellpadding="1" cellspacing="1" width="100%" style="text-align: center;">
                        <tr>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ProjectedBISupportTeamRI", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ProjectedBISupportTeamTX", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ProjectedBISupportTeamMD", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ProjectedDESupportTeamRI", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ProjectedDESupportTeamTX", "{0:n1}")%></td>
                            <td style="width: 14%; border-bottom: none;"><%#Eval("ProjectedDESupportTeamMD", "{0:n1}")%></td>
                            <td style="width: 16%; border-bottom: none;"><%#Eval("ProjectedSupportTeamTotal", "{0:n1}")%></td>
                        </tr>
                    </table>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
<%--            <telerik:GridTemplateColumn DataField="ProdActualBICasesClosed" Display="False" 
                HeaderText="Total" SortExpression="ProdActualBICasesClosed" 
                UniqueName="ProdActualBICasesClosed">
                <HeaderStyle Width="0px" />
                <EditItemTemplate>
                    <telerik:RadNumericTextBox ID="TextBox_ProdActualBICasesClosed" runat="server" DbValue='<%# Bind("ProdActualBICasesClosed", "{0:n1}") %>'
                        Width="30px"></telerik:RadNumericTextBox>
                    <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ProdActualBICasesClosed" runat="server"
                            errormessage="*" controltovalidate="TextBox_ProdActualBICasesClosed">
                    </asp:RequiredFieldValidator></span>
                </EditItemTemplate>
                <ItemTemplate>
                    <asp:Label ID="ProdActualBICasesClosedLabel" runat="server" 
                        Text='<%# Eval("ProdActualBICasesClosed", "{0:n1}") %>' Width="30px" ></asp:Label>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn DataField="ProdProjectedBICasesClosed" 
                Display="False" HeaderText="Total" SortExpression="ProdProjectedBICasesClosed" 
                UniqueName="ProdProjectedBICasesClosed">
                <HeaderStyle Width="0px" />
                <EditItemTemplate>
                    <telerik:RadNumericTextBox ID="TextBox_ProdProjectedBICasesClosed" runat="server"
                        DbValue='<%# Bind("ProdProjectedBICasesClosed", "{0:n1}") %>' Width="30px"></telerik:RadNumericTextBox>
                    <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ProdProjectedBICasesClosed"
                            runat="server" errormessage="*" controltovalidate="TextBox_ProdProjectedBICasesClosed">
                    </asp:RequiredFieldValidator></span>
                </EditItemTemplate>
                <ItemTemplate>
                    <asp:Label ID="ProdProjectedBICasesClosedLabel" runat="server" 
                        Text='<%# Eval("ProdProjectedBICasesClosed", "{0:n1}") %>' ></asp:Label>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn DataField="ProdActualDECasesClosed" Display="False" 
                HeaderText="Total" SortExpression="ProdActualDECasesClosed" 
                UniqueName="ProdActualDECasesClosed">
                <HeaderStyle Width="0px" />
                <EditItemTemplate>
                    <telerik:RadNumericTextBox ID="TextBox_ProdActualDECasesClosed" runat="server" DbValue='<%# Bind("ProdActualDECasesClosed", "{0:n1}") %>'
                        Width="30px"></telerik:RadNumericTextBox>
                    <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ProdActualDECasesClosed" runat="server"
                            errormessage="*" controltovalidate="TextBox_ProdActualDECasesClosed">
                    </asp:RequiredFieldValidator></span>
                </EditItemTemplate>
                <ItemTemplate>
                    <asp:Label ID="ProdActualDECasesClosedLabel" runat="server" 
                        Text='<%# Eval("ProdActualDECasesClosed", "{0:n1}") %>' ></asp:Label>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn DataField="ProdProjectedDECasesClosed" 
                Display="False" HeaderText="Total" SortExpression="ProdProjectedDECasesClosed" 
                UniqueName="ProdProjectedDECasesClosed">
                <HeaderStyle Width="0px" />
                <EditItemTemplate>
                    <telerik:RadNumericTextBox ID="TextBox_ProdProjectedDECasesClosed" runat="server"
                        DbValue='<%# Bind("ProdProjectedDECasesClosed", "{0:n1}") %>' ></telerik:RadNumericTextBox>
                    <span style="color:Red;"><asp:RequiredFieldValidator id="RequiredFieldValidator_ProdProjectedDECasesClosed"
                            runat="server" errormessage="*" controltovalidate="TextBox_ProdProjectedDECasesClosed">
                    </asp:RequiredFieldValidator></span>
                </EditItemTemplate>
                <ItemTemplate>
                    <asp:Label ID="ProdProjectedDECasesClosedLabel" runat="server" 
                        Text='<%# Eval("ProdProjectedDECasesClosed", "{0:n1}") %>'></asp:Label>
                </ItemTemplate>
            </telerik:GridTemplateColumn>       
--%>        </Columns>
        <EditFormSettings>
        <EditColumn UniqueName="EditCommandColumn1"></EditColumn>
        </EditFormSettings>
        <ItemStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" 
            Font-Strikeout="False" Font-Underline="False" HorizontalAlign="Center" 
            Wrap="True" VerticalAlign="Middle" />
        <AlternatingItemStyle Font-Bold="False" Font-Italic="False" 
            Font-Overline="False" Font-Strikeout="False" Font-Underline="False" 
            HorizontalAlign="Center" Wrap="True" VerticalAlign="Middle" />
        <EditItemStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" 
            Font-Strikeout="False" Font-Underline="False" HorizontalAlign="Center" 
            Wrap="True" VerticalAlign="Middle" />
        <PagerStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" 
            Font-Strikeout="False" Font-Underline="False" HorizontalAlign="Center" 
            VerticalAlign="Middle" Wrap="True" AlwaysVisible="True" />
        <HeaderStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" 
            Font-Strikeout="False" Font-Underline="False" HorizontalAlign="Center" 
            Wrap="True" VerticalAlign="Bottom" />
    </MasterTableView>
    <HeaderStyle BorderStyle="None" />
</telerik:RadGrid>

I've also attached snapshots showing how both the Actual (correct) and Projected (incorrect) are being rendered by the RadGrid, in case this helps.

All help appreciated!

Jon
Marin
Telerik team
 answered on 15 Feb 2011
2 answers
108 views
I've handled OnClientItemsRequesting for radComboBox. Below is the handler code.

function OnClientItemsRequestingHandler(sender, eventArgs)
{
    if (sender._cachedText != unescape(sender._callbacktext))
    {
        sender.clearItems();
    }
}


I'm clearing out all items from the combobox before callback if the search text has changed since last callback.
sender._cachedText gives current value entered for search in combobox
sender._callbacktext gives last callback value.
I get the intended behavior in IE all versions.Whne user changes searchtext, items are cleared (as both the text are different). When user clicks on More Results box, the items are not cleared (as both the text are same)

When in Firefox, sender._cachedText  is always empty. Cant figure out why.
nk
Top achievements
Rank 1
 answered on 15 Feb 2011
1 answer
211 views
I use RadWindow to pup up various dialog windows and forms for my users. I almost always specify the height and width of the popup in order to display the form properly. What is happening is, if the user pops the form up on a screen which doesn't have sufficient height available (due to too many browser toolbars, or small screen size overall), then the RadWindow header gets cut off altogether and the user is not able to drag the window down (because the header is not visible). Not being able to get access to the rad window header also means the close, min/max buttons are not visible, which could be useful to try and display the window properly in their available screen size. In the future, I will probably be able to implement some funcitonality which checks the user's available screen height and opens the window to a height value less than this. However, is there some built-in rad window funcitonality that can prevent the header from being hidden? I have attached a screen capture of an extreme example where the header gets cut off because of a lack of available screen height.
Cori
Top achievements
Rank 2
 answered on 15 Feb 2011
1 answer
101 views
Hi,

I have a custom validator for my upload control that checks to see if a there is a file set and b if the file type is correct.  This works fine in the main.

The problem that I am having is that if you click on the upload button for the form before a file is selected the validation fires and shows that the file is missing, BUT when you then select a file the validator doesn't fire again to clear the error message.  The form can be submitted thus triggering the validation though.

Please could functionality be added to the control so that validation can be triggered after the select button has been pressed?  At the moment many telerik editor controls seem to be like this while others revalidate on leaving the field.  Eg Combo box.

Regards,

Jon
Cori
Top achievements
Rank 2
 answered on 15 Feb 2011
8 answers
230 views
if i have a list of elements that display the menu when selected.  When a menu item is selected on the client it fires the server event  OnItemClick="ContextMenuSelected" 

html

<a ondblclick="showMenu(event)">102.</a>

protected

void ContextMenuSelected(object sender, RadMenuEventArgs e)

{

Telerik.Web.UI.

RadMenuItem ItemClicked = e.Item;
System.Diagnostics.Debug.WriteLine("Server event raised -- you clicked: " + ItemClicked.Text);
}

How can I tell which page element the item was selected from.  i want to know that it was 102. that the menu was called from

Thanks,
Chris

Yana
Telerik team
 answered on 15 Feb 2011
9 answers
148 views
Greetings,

is it possible to recognize, whether there is filter applied on a column in case of using IsNull or NotIsNull conditions? I did not succeed to apply background color to filter cell, where filter was on. Or is there another way to differentiate filter cell when filter is used for the column?

Thank you very much.
Igor
Top achievements
Rank 1
 answered on 15 Feb 2011
1 answer
137 views
Hi

How do I transfer items between listboxes server side?
In the page load I want to fill the source listbox and then transfer some items out of it to the destination listbox before it is displayed to the user.
The demos in this thread are of no use to me because I am not using a static list and will not be binding / updating to a datasource directly.

Thanks!
Dimitar Terziev
Telerik team
 answered on 15 Feb 2011
3 answers
419 views
I have an information form that is validated via captcha in my web application which is really important for me.
Captcha's default source link is like this: (mydomain/Telerik.Web.UI.WebResource.axd?type=rca&guid=e0616d29-d122-4be0-9b0f-bd6676a0c15c)

if one of xss attack makes some changes on requested parameter "guid", an empty image returns, and RadCaptcha.isValid is set to false, ok,  but if requested parameter "guid" is set to empty or space character, captcha returns empty and RadCaptha.isValid is set to TRUE.

Example source: (mydomain/Telerik.Web.UI.WebResource.axd?type=rca&guid= )

any ideas? thanks.
Pero
Telerik team
 answered on 15 Feb 2011
3 answers
149 views
Hi Telerik,
    We are using telerik rad editor 5.6.1.0 licensed version. We are facing issues when we add content in the design tab and when try to apply some of the bullet classes from the Apply CSS Drop down.We are facing issues with all the bullet classes and numbered classes for example like ms-rteCustom-Squarebulletlist and also same problem comes with  our custom bullet classes as well.
In the edit page when we try to apply any of the bulleted classes or numbered classes it waits for a long time but no styles get applied.From the telerik support blogs we found that some of the parent CSS may get override with telerik classes, so we have removed parent CSS still we are facing the same issue.I have attached some of the ScreenShots for more clarifications.

Seeking your reply ASAP.Thanks In advance.



With Regards,
Velu Soubramanien
Stanimir
Telerik team
 answered on 15 Feb 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?