Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
115 views
When utilizing the context menu filtering it works fine for adding 1 filter. If you do another action, like sort or add another filter, it keeps the previous filter but doesn't show it in the menu. If you click "Clear Filter" it does clear the filter that you don't see and refreshes the grid as you would expect. It doesn't do this in the Telerik demo, so I'm thinking there's something wrong with my code or there's been a fix since the Telerik build we're using (2013.2.717.35). Any ideas? Thanks.

<
telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
    <script type="text/javascript">
        var cancelAjax = false;
 
        function RequestStart(sender, eventArgs) {
            if ((eventArgs.get_eventTarget() == "ctl00$ContentPlaceHolder1$ShipClassGridView$ctl00$ctl02$ctl00$WirsRadToolBar") &&
           (cancelAjax)) {
                eventArgs.set_enableAjax(false);
            }
            else eventArgs.set_enableAjax(true);
        }
 
        function OnClientButtonClickingHandler(sender, eventArgs) {
            if (eventArgs.get_item().get_value() == "NoAjax") {
                cancelAjax = true;
            }
        }
 
        function ShowColumnHeaderMenu(ev, columnName) {
            var grid = window.$find("<%=ShipClassGridView.ID %>");
            var columns = grid.get_masterTableView().get_columns();
 
            for (var i = 0; i < columns.length; i++) {
                if (columns[i].get_uniqueName() == columnName) {
                    columns[i].showHeaderMenu(ev, 75, 20);
                }
            }
        }
    </script>
</telerik:RadCodeBlock>
<telerik:RadGrid ID="ShipClassGridView" runat="server" AllowAutomaticDeletes="false"
    EnableViewState="false" Visible="true" AllowAutomaticInserts="false" AllowAutomaticUpdates="false"
    EnableAJAX="true" GroupingEnabled="false" Skin="WIRS" EnableEmbeddedSkins="false"
    GridLines="None" OnItemCommand="ShipClassGridView_ItemCommand" OnNeedDataSource="ShipClassGridView_NeedDataSource"
    GroupingSettings-CaseSensitive="false" AllowSorting="True" EnableHeaderContextMenu="true"
    EnableHeaderContextFilterMenu="true" AllowFilteringByColumn="true" EnableLinqExpressions="false"
    OnItemDataBound="ShipClassGridView_OnItemDataBound" AutoGenerateColumns="False">
    <ExportSettings ExportOnlyData="true" IgnorePaging="true" OpenInNewWindow="true">
        <Excel Format="Biff" />
    </ExportSettings>
    <MasterTableView DataKeyNames="Id" IsFilterItemExpanded="false" AllowFilteringByColumn="true"
        CommandItemDisplay="Top" EnableNoRecordsTemplate="true">
        <NoRecordsTemplate>
            No results found for the selected ship class.</NoRecordsTemplate>
        <CommandItemTemplate>
            <telerik:RadToolBar runat="server" EnableEmbeddedSkins="false" Skin="WIRS" ID="WirsRadToolBar"
                Width="100%" OnClientButtonClicking="OnClientButtonClickingHandler" OnButtonClick="WirsRadToolBar_ButtonClick">
                <Items>
                    <telerik:RadToolBarButton Text="Export to Excel" Value="NoAjax" CommandName="ExportExcel"
                        ImageUrl="../images/Toolbar/xls.gif" />
                    <telerik:RadToolBarButton Text="Export to PDF" Value="NoAjax" CommandName="ExportPdf"
                        ImageUrl="../images/Toolbar/pdf.gif" />
                </Items>
            </telerik:RadToolBar>
        </CommandItemTemplate>
        <CommandItemSettings ShowAddNewRecordButton="false" ShowExportToPdfButton="true" />
        <Columns>
            <telerik:GridBoundColumn DataField="Id" HeaderText="Id" SortExpression="Id" AllowFiltering="false"
                Visible="false" />
            <telerik:GridTemplateColumn HeaderText="Hull Number" DataField="Hull" DataType="System.String"
                SortExpression="Hull">
                <ItemTemplate>
                    <asp:Label ID="HullLabel" runat="server" Text='<%# Eval("Hull") %>' Style="position: relative;
                        top: -3px;"></asp:Label>
                    <asp:Image ID="ImageHullNo" runat="server" ImageUrl="../images/New/eo_web.ashx.gif"
                        Visible="false" />
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridBoundColumn DataField="Name" HeaderText="Name" SortExpression="Name" />
            <telerik:GridDateTimeColumn HeaderText="Last Modified" DataField="LastUpdateDate"
                SortExpression="LastUpdateDate" DataFormatString="{0:d}" UniqueName="LastUpdateDate"
                PickerType="None" />
            <telerik:GridBoundColumn DataField="ModifiedByDisplayName" HeaderText="Last Modified By"
                SortExpression="ModifiedByDisplayName" />
            <telerik:GridNumericColumn HeaderText="Total Records" DataField="WirsRowCount" SortExpression="WirsRowCount"
                UniqueName="WirsRowCount" />
            <telerik:GridTemplateColumn AllowFiltering="false" HeaderText="Ship Status">
                <ItemTemplate>
                    <asp:Label ID="RecordStatusLbl" runat="server" />
                </ItemTemplate>
            </telerik:GridTemplateColumn>
        </Columns>
    </MasterTableView>
    <ClientSettings EnableRowHoverStyle="true" Resizing-AllowColumnResize="true" AllowColumnsReorder="true" />
</telerik:RadGrid>
Mike
Top achievements
Rank 1
 answered on 21 Oct 2014
3 answers
276 views
Currently Insert image option on your control is inserting image to editor by giving it a URL like "https:/localhost/MyProject/ImageName.jpg" but can i insert an image from client machine. like in the case of Upload where i choose from machine
i want insert image to choose image from machine instead of dialog box asking for URL....
Vessy
Telerik team
 answered on 21 Oct 2014
3 answers
124 views
How can I transfer the url of the document I click on the AddressBox?
So when I click on a documented as shown in the AddressBox complete URL as www.mydomain.se/documents/mydocument.pdf
Vessy
Telerik team
 answered on 21 Oct 2014
1 answer
573 views
I am designing a new page and decided to 100% telerik, no asp controls.  I have a question on the radTextbox, it says its HTML5 compatabile for an input type but when I put an input type of numbers and go into IE11, it still allows text in the text box, I would think this would only allow numbers.  I see there is a radNumericTextbox that achieves my numbers on textbox, but why both if they support HTML5?

<td style="width:25%;text-align:right">Est. Attendance:</td>
               <td><telerik:RadTextBox ID="txtAttendance2" runat="server" Width="80px" MaxLength="4" InputType="Number"></telerik:RadTextBox>
                   <telerik:RadNumericTextBox ID="txtAttendance" runat="server" Width="80px" MaxLength="4"></telerik:RadNumericTextBox>
               </td>
Viktor Tachev
Telerik team
 answered on 21 Oct 2014
2 answers
215 views
Not a question, but a discovery that I didn't see documented...

I wanted to add a custom tooltip to my sparkline column chart. However, I kept getting duplicate series values showing in the tooltip. (See the image "sparkline-tooltip-series.jpg.)" It seems that the series value is displayed in addition to whatever you put in the template if the template is added to the Series. Here is the code behind the example in the image:

<telerik:RadHtmlChart runat="server" ID="rhcSol" Layout="Sparkline" Width="150px" Height="40px">
  <PlotArea>
    <Series>
      <telerik:ColumnSeries DataFieldY="cxCount">
        <Appearance FillStyle-BackgroundColor="Red"></Appearance>
        <TooltipsAppearance>
          <ClientTemplate><div style="color:white;">Sol #= category #</div>
      <div> #= value #</div>
          </ClientTemplate>
        </TooltipsAppearance>
      </telerik:ColumnSeries>
    </Series>
    <XAxis DataLabelsField="sol"></XAxis>
  </PlotArea>
  <Legend>
    <Appearance Visible="false"></Appearance>
  </Legend>
</telerik:RadHtmlChart>



To avoid this extra appearance of the series value, you have to use a shared template and put it in the PlotArea (not the Series). Code example for sparkline-tooltip-shared.jpg:

<telerik:RadHtmlChart runat="server" ID="rhcSol" Layout="Sparkline" Width="150px" Height="40px">
  <PlotArea>
    <CommonTooltipsAppearance Shared="true" Visible="true">
      <SharedTemplate><div style="color:white;">Sol #= category #</div>
      <div style="text-align:right;"> #= points[i].value #</div>
      </SharedTemplate>
    </CommonTooltipsAppearance>
    <Series>
      <telerik:ColumnSeries DataFieldY="cxCount">
        <Appearance FillStyle-BackgroundColor="Red"></Appearance>
        <TooltipsAppearance>
        </TooltipsAppearance>
      </telerik:ColumnSeries>
    </Series>
    <XAxis DataLabelsField="sol"></XAxis>
  </PlotArea>
  <Legend>
    <Appearance Visible="false"></Appearance>
  </Legend>
</telerik:RadHtmlChart>
Tom
Top achievements
Rank 1
 answered on 21 Oct 2014
4 answers
212 views
I am doing the data binding and filtering using the client side scripting.

I have set the following attributes for the GridDateTimeColumn:

GridDateTimeColumn.CurrentFilterFunction = GridKnownFunction.Between
GridDateTimeColumn.EnableRangeFiltering = True
GridDateTimeColumn.EnableTimeIndependentFiltering = True

The filter command is firing when i entered date in the From and To textboxes. That is fine.
The problem is, once i cleared both the textboxes, the filter command is not firing.
Also, when the filter command is firing for other columns, it still keeps the value entered in the From and To textboxes of the GridDateTimeColumn.

So, please help me how to invoke filter command as the command name as "NoFilter" if the filter value is cleared by the user.
Valli
Top achievements
Rank 1
 answered on 21 Oct 2014
1 answer
135 views
I have a RadWindow to show comments when I click button of GridButtonColumn of a RadGrid. When I click, in the ItemCommand event of the RadGrid I have the following code:

protected void rgQualityReport_OnItemCommand(object sender, GridCommandEventArgs e)
{
    if (e.CommandName == "ShowComment")
    {
        GridDataItem dataItem = e.Item as GridDataItem;
        comments.Content = dataItem["ColumnDate"].Text;
        this.modalPopupComments.VisibleOnPageLoad = true;
        RadWindowManager1.DestroyOnClose = true;
        RadWindowManager1.Controls.Add(modalPopupComments);
    }
}


The problem is the following:When I click the button, the radwindow is showed correctly. However, after close the radwindow and reload the page, in a postback reload I have the following error:sys.webforms.pagerequestmanagerservererrorexception JSCRIPT error.

Can you help me, please?Thanks!
Maria Ilieva
Telerik team
 answered on 21 Oct 2014
1 answer
613 views
Hi!
Is there any way in Telerik to have a responsive grid? I use it in a web page and with a lot of column headers, I wish it was as responsive as the grid in the link below for every device in any resolution: 
http://fooplugins.com/footable-demos/
Alternatively, is there any way to integrate footable attributes in a telerik radgrid?

Thanks!
Pavlina
Telerik team
 answered on 21 Oct 2014
3 answers
228 views
We have had our RadEditor working with a custom editor CSS file for a while, and the "Select CSS Class" dropdown properly shows just the classes in that file. I've been asked to add a TableLayoutCSSFile to provide a custom table format. Once I add the table file to the config, the table styles begin showing in the class dropdown.

Is there any way to prevent this? We don't want users to have to scroll through tons of table styles, just to get to the content styles at the bottom of the list.
Ianko
Telerik team
 answered on 21 Oct 2014
1 answer
146 views
Hi,

We were using ASP.net AJAX Q2 2013 along with VS 2010 for our development. Recently we upgraded the environment to VS 2013 and Telerik  ASP.net AJAX Q3 2013 RAD Controls.  Now we find that in all the web pages where we have the RAD Date picker, the control flickers in IE11 on post back. Also for drop down lists, the user has to click twice to get it working. There is a considerable slowness in these controls.  This is happening only in IE11 and works fine in chrome.  This was working correctly in IE 11 when we were using Q2 2013.  We cannot tell our clients to use chrome since our application works best in IE. 

We are now hesitating to provide our latest build to our clients due to the slowness of these controls.  What could be the possible issue and are there any workarounds or fixes for this? An early action from your end is appreciated.  

Thanks and Regards

Rajendran Valappil
Maria Ilieva
Telerik team
 answered on 21 Oct 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?