Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
341 views
Have Pdf-DefaultFontFamily='Arial Unicode MS' set in <ExportSettings>. 

Works fine when exporting on local machine.   When I deploy and run from azure website, export appears to be in Times New Roman.

Any suggestions?

Regards

Glenn
Daniel
Telerik team
 answered on 30 Apr 2014
5 answers
176 views
Hello all,

I was wondering if it is possible to achieve a notification about required fields. I was adapting the example at https://demos.telerik.com/aspnet-ajax/notification/examples/waiariasupport/defaultcs.aspx (the primary feature here is checking if there are errors, not the ARIA-support).

At least, I got stuck with the client having to call "showNotification()". In the example it is done by a simple button underneath the form, but in my example I'm using a relatively complex RadGrid with EditMode set to PopUp.

All in all, I want the following features:

- adding or editing a dataset should open a modal popup with edit fields in it, including buttons "update" and "cancel" (done by RadGrid EditMode="popup")
- show a RadNotification if the first two fields (shortname and definition) are empty, DO NOT close the form
- if at least the two fields are given, insert / update the dataset

I hope you can help me and I am really looking forward to a nice solution,

regards

Jan
Jan
Top achievements
Rank 1
 answered on 30 Apr 2014
9 answers
182 views
I have the following User Control:
<%@ Control Language="C#" AutoEventWireup="true" CodeFile="test.ascx.cs" Inherits="_Controls_test" %>
<asp:Button ID="btnText" runat="server" Text="test" OnClick="btnTest_Click" />
protected void btnTest_Click(object sender, EventArgs e)
  {
    CommandEventArgs args = new CommandEventArgs("TestEvent", "bubbled up!");
    RaiseBubbleEvent(null, args);
  }

Then a parent page:
<telerik:RadScriptManager ID="ScriptManager1" runat="server" />
    <telerik:RadAjaxPanel ID="UpdatePanel1" runat="server" LoadingPanelID="UpdateProgress1">
      This is a test page:<br />
      <asp:Literal ID="litTest" runat="server" />
      <br /><br /><br />
      <uc1:testUC ID="testUC1" runat="server" />
    </telerik:RadAjaxPanel>
    <telerik:RadAjaxLoadingPanel ID="UpdateProgress1" runat="server" />
protected override bool OnBubbleEvent(object source, EventArgs args)
  {
    if (args != null)
    {
      CommandEventArgs e = (CommandEventArgs)args;
      if (e.CommandArgument != null)
      {
        litTest.Text += e.CommandName + " = " + e.CommandArgument.ToString() + "<br />";
        return true;
      }
    }
 
    return false;
  }

When the button is clicked, the OnBubbleEvent is not fired - if I replace the RadAjaxPanel with an UpdatePanel, it fires (twice, strangely?). If I remove the UpdaetPanel and have it post back, it also fires twice. WHat do I need to do to get this working in RadAjaxPanel?
Maria Ilieva
Telerik team
 answered on 30 Apr 2014
5 answers
469 views
I'm having trouble writing a pdf file to the browser when a user clicks a linkbutton inside a radgrid detailview gridtableview gridtemplatecolumn.  The grid is also wrapped in an update panel. The click event fires and the bytes are written to the response without error.  However the browser's file download dialog never appears.

Any insights would be greatly appreciated.

<asp:UpdatePanel ID="updatePanel" ClientIDMode="Static" runat="server">
            <ContentTemplate>
    <telerik:RadGrid ID="rgDocuments" runat="server" Width="100%" ShowStatusBar="False" AutoGenerateColumns="False"
        AllowSorting="False" AllowMultiRowSelection="False" AllowPaging="False" Skin="EACS" EnableEmbeddedSkins="false"
        OnDetailTableDataBind="rgDocuments_DetailTableDataBind" OnNeedDataSource="rgDocuments_NeedDataSource"
        OnPreRender="rgDocuments_PreRender">
        <MasterTableView Width="100%" DataKeyNames="DOCUMENT_AUTHOR_ID" AllowMultiColumnSorting="True">
            <DetailTables>
                <telerik:GridTableView DataKeyNames="DOCUMENT_AUTHOR_ID,DOCUMENT_AUTHOR_CATEGORY_ID" Name="Categories" Width="100%" >
                    <DetailTables>
                        <telerik:GridTableView DataKeyNames="DOCUMENT_ID,PARENT_DOCUMENT_ID" Name="ParentDocuments" Width="100%">
                            <DetailTables>
                                <telerik:GridTableView DataKeyNames="DOCUMENT_ID,FILENAME,TITLE" Name="Documents" Width="100%">                           
                                    <Columns>
                                        <telerik:GridBoundColumn DataField="DOCUMENT_ID" Visible="false">
                                        </telerik:GridBoundColumn>
                                        <telerik:GridBoundColumn DataField="FILENAME" Visible="false">
                                        </telerik:GridBoundColumn>
                                        <telerik:GridTemplateColumn HeaderText="Section Title">
                                            <ItemTemplate>
                                                   <asp:LinkButton ID="btnDocument" runat="server" OnClick="btnDocument_Click" Text='<%# Eval("Title") %>'></asp:LinkButton>
                                              </ItemTemplate>
                                        </telerik:GridTemplateColumn>
                                    </Columns>
                                </telerik:GridTableView>
                            </DetailTables>
                            <Columns>
                                <telerik:GridBoundColumn DataField="DOCUMENT_ID" Visible="false">
                                </telerik:GridBoundColumn>                               
                                <telerik:GridBoundColumn HeaderText="Document Title" DataField="TITLE" >
                                </telerik:GridBoundColumn>
                            </Columns>
                        </telerik:GridTableView>
                    </DetailTables>
                    <Columns>
                        <telerik:GridBoundColumn DataField="DOCUMENT_AUTHOR_CATEGORY_ID" Display="false">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn HeaderText="Category" DataField="DISPLAY_VALUE">
                        </telerik:GridBoundColumn>
                    </Columns>
                </telerik:GridTableView>
            </DetailTables>
            <Columns>
                <telerik:GridBoundColumn DataField="DOCUMENT_AUTHOR_ID" Visible="false"></telerik:GridBoundColumn>
                <telerik:GridBoundColumn HeaderText="Author Name" DataField="DISPLAY_VALUE"></telerik:GridBoundColumn>
            </Columns>
        </MasterTableView>
    </telerik:RadGrid>
    </ContentTemplate>
    </asp:UpdatePanel>

protected void btnDocument_Click(object sender, EventArgs e)
        {
            LinkButton lb = (LinkButton)sender;
            GridDataItem item = (GridDataItem)lb.NamingContainer;
            if (item != null)
            {
                string documentUploadPath = ConfigurationManager.AppSettings["DocumentUploadPath"].ToString();               
                string filename = documentUploadPath + item.GetDataKeyValue("FILENAME").ToString();
                string title = documentUploadPath + item.GetDataKeyValue("TITLE").ToString();
 
                if (File.Exists(Server.MapPath(filename)))
                {
                    System.Web.HttpResponse response = System.Web.HttpContext.Current.Response;
 
                    byte[] bytes = File.ReadAllBytes(Server.MapPath(filename));
 
                    response.Clear();
                    response.AddHeader("Content-Type", "binary/octet-stream");
                    response.AddHeader("Content-Disposition",
                        "attachment; filename=" + title + ".pdf;");
                    response.Flush();
                    response.BinaryWrite(bytes);
                    response.Flush();
                    response.End();
                }
            }
        }

Stephen
Top achievements
Rank 1
 answered on 30 Apr 2014
1 answer
119 views
Hi, I am using 2013 Q3 version.  I have a problem as follows:

In client side, I have defined RadGrid and the corresponding ClientSettings as follows:
<telerik:RadGrid runat="server" ID="OrgGrid" AutoGenerateColumns="False" AllowSorting="True" AllowFilteringByColumn="True"
                         AllowPaging="True" AllowCustomPaging="true" CellSpacing="0" EnableLinqExpressions="false"
                         EnableViewState="true" ShowGroupPanel="True">
            <ClientSettings AllowColumnsReorder="true" AllowDragToGroup="true" ReorderColumnsOnClient="true">
                <Resizing AllowColumnResize="true" AllowRowResize="false" ResizeGridOnColumnResize="true" />
                <ClientEvents OnColumnResized="OnColumnResized" />
            </ClientSettings>
      ....

I would like to know the way to set the textbox width in the FilteringItem in OnColumnResized event.  I tried the following but it doesn't return anything to me in the textbox.
            function OnColumnResized(sender, eventArgs) {
                var _OrgGrid = $find("<%= OrgGrid.ClientID %>");
                var _MasterTableView = _OrgGrid.get_masterTableView();
                var _filterRow = $telerik.$(_OrgGrid.get_element()).find("rgFilterRow");
                var _textbox = $telerik.findElement(_filterRow[0], "OrgCode");
                _textbox.width = eventArgs.get_gridColumn().get_element().offsetWidth - 40;

                return false;
            }  

Thanks.
Emily



Princy
Top achievements
Rank 2
 answered on 30 Apr 2014
7 answers
840 views
Hi!

I'm trying to validate the content of a Prometheus ComboBox. But I'm facing a "small" problem. This is what I have:

- A RadComboBox;
- A RequiredFieldValidator (validating the combo)
- A button

When I press the button, it postbacks to the server, and after that, it shows the warning message saying that the field is not filled.

Shouldn't the validator validate the page on the Client? Please tell me that I'm missing something... Do I have to set any other properties on the combox to get this to work?

Thanks!
Princy
Top achievements
Rank 2
 answered on 30 Apr 2014
7 answers
344 views
Hi,

When a textbox is in an updatepanel, and trying to enter large content, the following error occurs:

System.ArgumentException: Error during serialization or deserialization using the JSON JavaScriptSerializer. The length of the string exceeds the value set on the maxJsonLength property.
Parameter name: input
   at System.Web.Script.Serialization.JavaScriptSerializer.Deserialize(JavaScriptSerializer serializer, String input, Type type, Int32 depthLimit)
   at Telerik.Web.UI.RadInputControl.LoadPostData(String postDataKey, NameValueCollection postCollection)
   at System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Regard
Andreas
Angel Petrov
Telerik team
 answered on 30 Apr 2014
4 answers
141 views
i want to get Group Header Text in Radgrid OnGroupCollapsing Event...i got header text in  server side event but i want in client side .so please help me.
Eyup
Telerik team
 answered on 30 Apr 2014
5 answers
252 views
Hi,

Does Telerik have anything similar to what DevExpress have on Custom Validation Summary Control. I am basically looking to have Hyperlinks on the Errors been displayed on the Validation Summary some of my forms are so long basically the user clicks on the hyperlink and puts a focus on the input field.

Please let me know

Thanks
Viktor Tachev
Telerik team
 answered on 30 Apr 2014
3 answers
132 views
Please add DropDownAutoWidth into your discovery online demo http://demos.telerik.com/aspnet-ajax/combobox/examples/configurator/defaultcs.aspx
Aneliya Petkova
Telerik team
 answered on 30 Apr 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Anislav
Top achievements
Rank 6
Silver
Bronze
Bronze
Jianxian
Top achievements
Rank 1
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Jim
Top achievements
Rank 2
Iron
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Anislav
Top achievements
Rank 6
Silver
Bronze
Bronze
Jianxian
Top achievements
Rank 1
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Jim
Top achievements
Rank 2
Iron
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?