Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
202 views

Hello

I have a small problem of display of my telerik objects on my page asp.net on the browser safari, the display is good on the other browser, chrome, firefox, IE

you have solutions ?
thank you

Houcine
Top achievements
Rank 1
 answered on 03 Jul 2019
6 answers
11.4K+ views
I get this error using Sitecore:

'~/Telerik.Web.UI.WebResource.axd' is missing in web.config. RadScriptManager requires a HttpHandler registration in web.config. Please, use the control Smart Tag to add the handler automatically, or see the help for more information: Controls > RadScriptManager

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.InvalidOperationException: '~/Telerik.Web.UI.WebResource.axd' is missing in web.config. RadScriptManager requires a HttpHandler registration in web.config. Please, use the control Smart Tag to add the handler automatically, or see the help for more information: Controls > RadScriptManager

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[InvalidOperationException: '~/Telerik.Web.UI.WebResource.axd' is missing in web.config. RadScriptManager requires a HttpHandler registration in web.config. Please, use the control Smart Tag to add the handler automatically, or see the help for more information: Controls > RadScriptManager]
   Telerik.Web.UI.RadScriptManager.OnPreRender(EventArgs e) +161
   System.Web.UI.Control.PreRenderRecursiveInternal() +80
   System.Web.UI.Control.PreRenderRecursiveInternal() +171
   System.Web.UI.Control.PreRenderRecursiveInternal() +171
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +842



I have tried adding lines like this with the correct versions for my DLLs:
        <add verb="*" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Version=2010.2.826.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" validate="false" />

I have this at the moment:
<add verb="*" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" />

If I create a blank page and drag the control on from my toolbox I get a red message on it saying 'Error Cannot render control' so I can't get it to auto add the necessary stuff into the web.config.

This works across our sites and on my colleagues computers but not mine.

What is missing?

Rumen
Telerik team
 answered on 03 Jul 2019
1 answer
403 views
I am getting the following error, "The following assembly has dependencies on a version of the .NET Framework that is higher than the target and might not load correctly during runtime causing a failure: Telerik.Web.Design, Version=2018.1.117.40, Culture=neutral, PublicKeyToken=121fae78165ba3d4. The dependencies are: System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089. You should either ensure that the dependent assembly is correct for the target framework, or ensure that the target framework you are addressing is that of the dependent assembly"
for the following Telerik items: Telerik.Web.design, Telerik.Web.UI, and Telerik.Web.Design twice.

I am using Visual Studio 2010 and pointing to the BIN 4.0 folder for the Telerik references. I get these messages if I use the 2018 or 2019 Telerik updates.

In the last few months, I have installed visual studio 2012 on my workstation for another .net 2012 application that does not use the Telerik tool.

To solve my problem, I am wondering if I should do one of the following:
1. Uninstall visual studio 2012 from my workstation. I do not need this version for the application I was looking at previously.
2. Upgrade my visual studio 2010 .net application to visual studio 2012. However I do not know if I will have upgrade issues with that code.
3. Would you tell me what you suggest that I do?
Rumen
Telerik team
 answered on 03 Jul 2019
9 answers
5.3K+ views
hey.. i have radgrid which has columns and i want to make the width of the column fit the content of it to avoid large spaces.. now iam using the headerstyle width thats control the width of all columns .. any solutions ..??
Francisco
Top achievements
Rank 1
 answered on 02 Jul 2019
3 answers
397 views

I believe this is a bug since it is causing unexpected results.

I have a grid which is bound client-side to a web service. It would appear that datetime columns are being displayed differently, depending on the user's clock settings. In my scenario, my grid has two such columns (declared below).

<telerik:GridDateTimeColumn HeaderText="Svc. Date" DataField="ServiceDate" DataType="System.DateTime" DataFormatString="{0:MM/dd/yy}" AllowFiltering="false">
    <HeaderStyle width="80px" HorizontalAlign="Left" BorderStyle="None"></HeaderStyle>
</telerik:GridDateTimeColumn>
<telerik:GridDateTimeColumn  HeaderText="Created When" DataField="CreatedWhen" DataType="System.DateTime" DataFormatString="{0:MM/dd/yy hh:mm:ss tt}" AllowFiltering="false">
    <HeaderStyle width="140px" HorizontalAlign="Left" BorderStyle="None"></HeaderStyle>
</telerik:GridDateTimeColumn>

For users who are in the Central US timezone, the "ServiceDate" column is showing as one day earlier, and the "CreatedWhen" column is showing as one hour earlier. When they switch their computer clock to Eastern Timezone (the correct zone for the data being retrieved), then the ServiceDate and CreatedWhen columns appear correctly.

Looking at the json being used to bind the grid to, for one row, these are the values being retrieved from the database...

"ServiceDate":"\/Date(1508904000000)\/", "CreatedWhen":"\/Date(1508942284530)\/"

So, it appears whatever mechanism the grid is using to convert these date objects to date literals is using the user's computer settings. Is this true?

I'm not sure this is a good implementation. The data being retrieved from the database is intended to be displayed as is. Any manipulations to customize for user timezone should be handled by the developer. After all, the grid does not know what timezone the data being retrieved is in, so how does it know how to convert to the user's local machine timezone?

In this case, the data being retreived was in Eastern US timezone. So, a date of '10/24/17', for instance, was being displayed as '10/23/17' (one hour earlier than 10/24/17 00:00:00, assumedly)

So, is there any way to prevent this behavior?

Attila Antal
Telerik team
 answered on 02 Jul 2019
4 answers
568 views

Hi,

While i try to edit my rad editor it through an error Cannot read property 'replace' of undefined.

 

Please help me.

 

Thanks,

Rajiv

Rajiv
Top achievements
Rank 1
 answered on 02 Jul 2019
1 answer
203 views
  • ASP.NET version: 4.0.30319
  • OS: Windows Server 2012 R2
  • Browser: Google Chrome v66.0.3359.139 (Official Build) (64-bit)
  • Exact Telerik Version: 2014.1.225.40 (2007-2014 Telerik AD)
  • Preferred programming language: VB.NET

Hello, I'm currently implementing infinite scroll/load more functionality for news articles on our website. Do you have any documentation or advice on how we can initialize the RadSocialShare control client-side? I can load the initial batch of articles with their respective RadSocialShare controls, but because we're adding load more, we don't have the title and url to share until the user scrolls to the bottom of the page. Is there a way to find out which components we need in order to wire up RadSocialShare controls for the subsequent batches of articles?

Thanks!

Charles
Top achievements
Rank 1
 answered on 01 Jul 2019
3 answers
896 views
I am hoping someone can point me in the right direction.  I have a dataset displaying in my RadGrid.  When we export to Excel (HTML) I would like to remove some of the rows - based on a DataKeyValue.  How/where would I do this?
Attila Antal
Telerik team
 answered on 01 Jul 2019
6 answers
698 views

I have a hyperlink within a Radgrid which opens up a RadWindow for the user. 

 

                                <telerik:GridTemplateColumn HeaderText="Id" ReadOnly="true" SortExpression="Lookup" UniqueName="Lookup">
                                    <ItemTemplate>
                                        <asp:HyperLink ID="hlWorkOrderId" Text='<%#Eval("Lookup")%>' NavigateUrl='<%#String.Format("javascript:openWindow({0});", Eval("WorkOrderId"))%>' Enabled='<%#String.IsNullOrEmpty(CurrentUser).Equals(False).ToString%>' runat="server" />
                                    </ItemTemplate>
                                </telerik:GridTemplateColumn>

The user is requesting that when they click on the hyperlink, they want that row in the grid highlighted.   How can I pass the selected row index to the javascript function in the Hyperlink?  

Vessy
Telerik team
 answered on 01 Jul 2019
6 answers
947 views
How do I get a reference to a button in a template column of my grid during PreRender?

Here is a grid (ShotDetail_RadGrid) that has tabs on each row of data. On the first of these tabs is another grid (Attachments_RadGrid) with the ImageButton I'm trying to get the reference to:
<telerik:RadGrid ID="ShotDetail_RadGrid" runat="server" DataSourceID="ShotDetail_SqlDataSource" Skin="Black"
    GridLines="None" ShowStatusBar="True" Width="1100px" CellSpacing="0" AutoGenerateColumns="False">
    <HierarchySettings ExpandTooltip="Show related merch" CollapseTooltip="Collapse merch"></HierarchySettings>
    <ExportSettings IgnorePaging="True">
        <Pdf PageBottomMargin="0.5in" PageHeight="8.5in" PageLeftMargin="0.35in" PageRightMargin="0.35in" PageTopMargin="0.5in"
            PageWidth="11in" />
    </ExportSettings>
    <ClientSettings>
        <Scrolling AllowScroll="True" UseStaticHeaders="True" />
    </ClientSettings>
    <MasterTableView DataKeyNames="ShotID" DataSourceID="ShotDetail_SqlDataSource" AllowCustomPaging="True">
        <NestedViewTemplate>
            <asp:Panel runat="server" ID="InnerContainer" CssClass="viewWrap" Visible="false">
                <telerik:RadTabStrip runat="server" ID="TabStip1" MultiPageID="Multipage1" SelectedIndex="0">
                    <Tabs>
                        <telerik:RadTab runat="server" Text="Merchandise" PageViewID="PageView1" Selected="True">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Shot Support" PageViewID="PageView2">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Completed Images">
                        </telerik:RadTab>
                    </Tabs>
                </telerik:RadTabStrip>
                <telerik:RadMultiPage runat="server" ID="Multipage1" SelectedIndex="0" RenderSelectedPageOnly="false">
                    <telerik:RadPageView runat="server" ID="PageView1">
                        <asp:Label ID="ShotID_Label" Text='<%# Eval("ShotID") %>' Visible="false" runat="server" />
                        <asp:SqlDataSource ID="Merch_SqlDataSource" runat="server" ConnectionString="<%$ ConnectionStrings:Alderman_ConnectionString %>"
                            SelectCommand="sp_web_Merch_Grid_sel" SelectCommandType="StoredProcedure">
                            <SelectParameters>
                                <asp:ControlParameter ControlID="ShotID_Label" PropertyName="Text" Type="Int32" Name="ShotID" />
                            </SelectParameters>
                        </asp:SqlDataSource>
                        <telerik:RadGrid ID="Merch_RadGrid" runat="server" AutoGenerateColumns="False" DataSourceID="Merch_SqlDataSource"
                            GridLines="None" CellSpacing="0">
                            <ClientSettings AllowColumnsReorder="True" ReorderColumnsOnClient="True">
                            </ClientSettings>
                            <MasterTableView DataSourceID="Merch_SqlDataSource">
                                <CommandItemSettings ExportToPdfText="Export to Pdf" />
                                <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
                                </RowIndicatorColumn>
                                <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
                                </ExpandCollapseColumn>
                                <Columns>
                                    <telerik:GridBoundColumn DataField="Barcode" DataType="System.Int64" Display="False" HeaderText="Barcode"
                                        UniqueName="Barcode">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="Source" HeaderText="Vendor" UniqueName="Source" FilterControlAltText="Filter Source column">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="Description" HeaderText="Description" UniqueName="Description">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="SKU" HeaderText="SKU" UniqueName="SKU">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="SKU2" HeaderText="SKU2" UniqueName="SKU2">
                                    </telerik:GridBoundColumn>
                                </Columns>
                                <EditFormSettings>
                                    <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                                    </EditColumn>
                                </EditFormSettings>
                            </MasterTableView>
                            <FilterMenu EnableImageSprites="False">
                            </FilterMenu>
                            <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default" EnableImageSprites="True">
                            </HeaderContextMenu>
                        </telerik:RadGrid>
                    </telerik:RadPageView>
                    <telerik:RadPageView runat="server" Width="100%" ID="PageView2">
                        <asp:SqlDataSource ID="Attachments_SqlDataSource" runat="server" ConnectionString="<%$ ConnectionStrings:Alderman_ConnectionString %>"
                            SelectCommand="SELECT [AttachmentTitle], [LinkedFromID] FROM [tAttachments] WHERE (([LinkedFromID] = @ShotID) AND ([LinkedFromTable] = @LinkedFromTable) AND (AttachmentIsInvalid = 0))">
                            <SelectParameters>
                                <asp:ControlParameter ControlID="ShotID_Label" PropertyName="Text" Type="Int32" Name="ShotID" />
                                <asp:Parameter DefaultValue="tShots" Name="LinkedFromTable" Type="String" />
                            </SelectParameters>
                        </asp:SqlDataSource>
                        <telerik:RadGrid ID="Attachments_RadGrid" runat="server" DataSourceID="Attachments_SqlDataSource" GridLines="None"
                            CellSpacing="0">
                            <MasterTableView DataSourceID="Attachments_SqlDataSource" AutoGenerateColumns="False">
                                <CommandItemSettings ExportToPdfText="Export to PDF" />
                                <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
                                </RowIndicatorColumn>
                                <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
                                </ExpandCollapseColumn>
                                <Columns>
                                    <telerik:GridTemplateColumn UniqueName="ColumnDownload">
                                        <ItemTemplate>
                                            <asp:ImageButton ID="DownloadForShot_ImageButton" runat="server" ImageUrl="~/Images/view.gif" OnClick="DownloadForShot_ImageButton_Click" />
                                            <asp:PlaceHolder ID="PlaceHolder1" runat="server"></asp:PlaceHolder>
                                        </ItemTemplate>
                                    </telerik:GridTemplateColumn>
                                    <telerik:GridBoundColumn DataField="AttachmentTitle" HeaderText="Documents" UniqueName="ColumnAttachment">
                                    </telerik:GridBoundColumn>
                                </Columns>
                                <EditFormSettings>
                                    <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                                    </EditColumn>
                                </EditFormSettings>
                            </MasterTableView>
                            <FilterMenu EnableImageSprites="False">
                            </FilterMenu>
                            <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default">
                            </HeaderContextMenu>
                        </telerik:RadGrid>
                    </telerik:RadPageView>
                </telerik:RadMultiPage>
            </asp:Panel>
        </NestedViewTemplate>
        <CommandItemSettings ExportToPdfText="Export to Pdf"></CommandItemSettings>
        <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
        </RowIndicatorColumn>
        <ExpandCollapseColumn Visible="True">
        </ExpandCollapseColumn>
        <Columns>
            <telerik:GridBoundColumn DataField="JobShot" HeaderText="Shot" UniqueName="JobShot">
                <HeaderStyle Width="100px" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="Description" HeaderText="Description" UniqueName="Description">
                <HeaderStyle Width="700px" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="MerchCount" DataType="System.Int16" HeaderText="Merch Count" UniqueName="MerchCount"
                AllowFiltering="False">
                <HeaderStyle Width="50px" />
                <ItemStyle Wrap="True" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="JobNumber" Display="False" HeaderText="JobNumber" UniqueName="JobNumber"
                FilterControlAltText="Filter JobNumber column">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="ShotID" DataType="System.Int32" HeaderText="ShotID" UniqueName="ShotID"
                Display="False">
            </telerik:GridBoundColumn>
        </Columns>
        <EditFormSettings>
            <EditColumn FilterControlAltText="Filter EditCommandColumn column">
            </EditColumn>
        </EditFormSettings>
        <PagerStyle AlwaysVisible="True" />
    </MasterTableView>
    <PagerStyle AlwaysVisible="True" />
    <FilterMenu EnableImageSprites="False">
    </FilterMenu>
    <HeaderContextMenu EnableImageSprites="True" CssClass="GridContextMenu GridContextMenu_Default">
    </HeaderContextMenu>
</telerik:RadGrid>

Here is my PreRender code. The viewImageButton is never set.
protected void ShotDetail_RadGrid_PreRender(object sender, EventArgs e)
{
    if (!Page.IsPostBack) {
        //*** Associate each Attachments_RadGrid with its own postback script to open the file.
        for (int i = 0; i <= ShotDetail_RadGrid.MasterTableView.Items.Count - 1; i++) {
            Panel aspPanel = ShotDetail_RadGrid.MasterTableView.Items(i).ChildItem.FindControl("InnerContainer");
            RadGrid attachmentsGrid = aspPanel.FindControl("Attachments_RadGrid");
 
            RadScriptManager ScriptManager1 = default(RadScriptManager);
            ScriptManager1 = (RadScriptManager)this.Parent.FindControl("RadScriptManager1");
            ScriptManager1.RegisterPostBackControl(attachmentsGrid);
 
            ImageButton viewImageButton = attachmentsGrid.MasterTableView.FindControl("DownloadForShot_ImageButton");
            viewImageButton.Attributes.Add("onclick", " ExportButtonClick ();");
        }
    }
}

Thanks!

Attila Antal
Telerik team
 answered on 01 Jul 2019
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?