Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
149 views

In the RadEditor, if there are any font attributes such as font size and fontname applied to the text then those settings are not preserved while exporting the text to rtf. Do let me know If anyone has encountered the problem and workaround for the same.

 

Thanks in advance.

Rumen
Telerik team
 answered on 26 Aug 2011
1 answer
115 views
HI,

Can i use telerik tool tip for a textbox. When a user clicks on textbox,  it should open a tooltip with that textbox it in  and user should be able to edit it and on closing it should  append changed text in to the textbox.

If so, Can you please provide a example.

Thanks,
Nimmy
Shinu
Top achievements
Rank 2
 answered on 26 Aug 2011
2 answers
150 views
When I type a long paragraph until the vertical scroll bar appears and then press enter key the scroll bar jumps up and I need to scroll it down to continue typing. Please let me know if there is something to fix this issue.
Rumen
Telerik team
 answered on 26 Aug 2011
2 answers
81 views
Hi Guys,
I'm dynamicly setting the DeletePaths, UploadPaths and ViewPaths based on some users credentials with the following code:

 

 

Dim viewImages As String() = New String() {"~/Images/" & ddMenuName.SelectedValue}

 

 

 

Dim uploadImages As String() = New String() {"~/Images/" & ddMenuName.SelectedValue}

 

 

 

Dim deleteImages As String() = New String() {"~/Images/" & ddMenuName.SelectedValue}

 

 

 

If Not IsPostBack Then

 

    RadEditor1.ImageManager.ViewPaths = viewImages

    RadEditor1.ImageManager.UploadPaths = uploadImages

    RadEditor1.ImageManager.DeletePaths = deleteImages

 

 

End If

This works very good, however the upload button is disabled. What am I doing wrong here?

 

Rumen
Telerik team
 answered on 26 Aug 2011
1 answer
102 views
What i need to do is hide a radgrid column and unhide one based on a date.  I got it to work so far to hide the first column but it will not unhide the second column.  Confused at this point??
<telerik:RadGrid ID="myGridPositions" runat="server" BorderWidth="1px" CellPadding="6" GridLines="None" BorderColor="#404040" Skin="Web20">
                                                  <MasterTableView Name="myRGDDMain" AutoGenerateColumns="false" DataKeyNames="intPositionId" Font-Names="Veranda,arial,sans-serif" HeaderStyle-HorizontalAlign="Center" 
                                                  BorderWidth="1px" Width="100%" ItemStyle-HorizontalAlign="Center">
                                                   <HeaderStyle Font-Bold="true" />
                                                   <AlternatingItemStyle BackColor="#B0C4DE" />
                                                           <Columns>
                                                               <telerik:GridBoundColumn DataField="strPosnTitle" HeaderText="TITLE" ItemStyle-HorizontalAlign="left" />
                                                               <telerik:GridBoundColumn DataField="strpara" HeaderText="PARA" ItemStyle-HorizontalAlign="Center" />
                                                               <telerik:GridBoundColumn DataField="strLine" HeaderText="LINE"  ItemStyle-HorizontalAlign="Center" />
                                                               <telerik:GridBoundColumn DataField="intPositionNum" HeaderText="POS"  ItemStyle-HorizontalAlign="Center" />
                                                               <telerik:GridBoundColumn DataField="strGrade" HeaderText="GR"  ItemStyle-HorizontalAlign="Center" />
                                                               <telerik:GridBoundColumn DataField="strMos" HeaderText="MOS"  ItemStyle-HorizontalAlign="Center" />
                                                               <telerik:GridBoundColumn DataField="strFullName" HeaderText="Filled By" ItemStyle-HorizontalAlign="Left" />
                                                               <telerik:GridtemplateColumn HeaderText="LT_MOB" ItemStyle-HorizontalAlign="Center" UniqueName="Latemob">
                                                                   <ItemTemplate>
                                                                       <asp:LinkButton ID="lnkLateMob" runat="server" CommandArgument='<%# bind("intPositionId") %>' CommandName="LateMob">LT_MOB</asp:LinkButton>
                                                                   </ItemTemplate>
                                                               </telerik:GridtemplateColumn>
                                                               <telerik:GridTemplateColumn HeaderText="Remove" ItemStyle-HorizontalAlign="Center">
                                                                   <ItemTemplate>
                                                                       <asp:LinkButton ID="lnkDelete" runat="server" CommandArgument='<%# bind("intPositionId") %>' CommandName="Remove">Remove</asp:LinkButton>
                                                                   </ItemTemplate>
                                                               </telerik:GridTemplateColumn>
                                                                <telerik:GridTemplateColumn HeaderText="Remove" ItemStyle-HorizontalAlign="Center" Visible="false" UniqueName="Refrad">
                                                                   <ItemTemplate>
                                                                       <asp:LinkButton ID="lnkRefrad" runat="server" CommandArgument='<%# bind("intPositionId") %>' CommandName="Refrad">Refrad</asp:LinkButton>
                                                                   </ItemTemplate>
                                                               </telerik:GridTemplateColumn>
                                                           </Columns>
                                                   </MasterTableView>
                                               </telerik:RadGrid>

Protected Sub myGridPositions_ItemDataBound(ByVal sender As Object, ByVal e As Telerik.Web.UI.GridItemEventArgs) Handles myGridPositions.ItemDataBound
       Dim Today As DateTime = Date.Now
       Dim deploy As DateTime
       sql = "Select dtDeploy from tblMobUnits where intUnitMobId = " & ddlUic.SelectedValue
       myDataTable = New DataTable
       myDataTable = getData(sql)
       If IsDBNull(myDataTable.Rows(0)(0)) Then
           deploy = Date.Now.AddDays(10)
       Else
           deploy = myDataTable.Rows(0)(0)
       End If
       If Today > deploy Then
           If TypeOf e.Item Is GridDataItem Then
               myGridPositions.MasterTableView.GetColumn("Latemob").Display = False
               myGridPositions.MasterTableView.GetColumn("Refrad").Display = True
           End If
       End If
       If TypeOf e.Item Is GridDataItem Then
           Dim Item As GridDataItem = DirectCast(e.Item, GridDataItem)
           Dim cell As TableCell = Item("strFullName")
           If cell.Text = " " Then
               Dim Late As LinkButton = DirectCast(Item.FindControl("lnkLateMob"), LinkButton)
               Late.Visible = False
               Dim Remove As LinkButton = DirectCast(Item.FindControl("lnkDelete"), LinkButton)
               Remove.Visible = False
           End If
       End If
   End Sub
Tsvetina
Telerik team
 answered on 26 Aug 2011
3 answers
84 views
I am using Telerik.Web.UI_2011_2_712. When opening any of the image/document etc managers, the dialog box is 510 px high with a 20px strip of images 30 px down from the top, 16 px wide but repeating horizontally the width of the dialog box. When I go to compatibility mode, the dialog box displays correctly and is 490px high.
Rumen
Telerik team
 answered on 26 Aug 2011
2 answers
88 views
Hi,

I just update a project to AJAX 2011.2.
This  added HtmlEncoding to the GridDropDownColumn.
I have several GridDropDownColumns where I build hyperlinks using the following property:
ListTextFormatString="<a href='CustomersEdit.aspx?LIFNR={0}'>{0}</a>"

After updating to Q2 I no longer get hyperlinks - instead I get the plain text.
Searching the forums I fond the "HtmlEncode" property - but this does only exist in "normal" Grid columns - not in GridDropDownColumns.

How can I overcome this issue with Q2?

Thanks in advance
Manfred
ManniAT
Top achievements
Rank 2
 answered on 26 Aug 2011
5 answers
268 views
Hi 

i'm exporting a radgrid and trying to format the date to a culture e.g en-us, en-gb.

i've looked at http://www.telerik.com/help/aspnet-ajax/grid-excelml-export.html

but this only allows me to specify shortdate, general date etc

what i want is to display it in the export as follows

en-us - 8/24/2011
en-gb - 24/8/2011

i have formatted it in the radgrid by setting the culture on the page_load

System.Threading.Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo(siteCulture);
RadGrid1.Rebind(); 

as i understand from http://www.telerik.com/community/forums/aspnet-ajax/grid/exportsettings-api.aspx

The export gets the data from the db and not the radgrid, so the format in the db is shown, is that right?

i am using onNeedDataSource to populate my radgrid

my current code for export cell styles is:

protected void RadGrid1_ExcelMLExportRowCreated(object source, GridExportExcelMLRowCreatedArgs e)
    {
        e.Row.Cells.GetCellByName("ItemCreatedWhen").StyleValue = "dateStyle";
    }
    
    protected void RadGrid1_ExcelMLExportStylesCreated(object source, GridExportExcelMLStyleCreatedArgs e)
    {
        foreach (StyleElement style in e.Styles)
        {
            switch (style.Id)
            {
                case "headerStyle":
                    style.FontStyle.Bold = true;
                    break;
                case "itemStyle":
                    style.InteriorStyle.Color = System.Drawing.Color.White;
                    style.InteriorStyle.Pattern = Telerik.Web.UI.GridExcelBuilder.InteriorPatternType.Solid;
                    break;
                case "alternatingItemStyle":
                    style.InteriorStyle.Color = System.Drawing.Color.LightBlue;
                    style.InteriorStyle.Pattern = Telerik.Web.UI.GridExcelBuilder.InteriorPatternType.Solid;
                    break;
                    
            }
            
        }
        StyleElement myStyle = new StyleElement("dateStyle");
        myStyle.NumberFormat.FormatType = NumberFormatType.ShortDate;
        myStyle.FontStyle.Bold = true;
        e.Styles.Add(myStyle);    
         
    }

how do i format the date as i want based on culture?

also the background colors i'm applying do not get added to the A column in the excel, why is this?

Thanks

Adam


Jayesh Goyani
Top achievements
Rank 2
 answered on 26 Aug 2011
2 answers
121 views
Helo to Telerik Team I need your help.I have an asp.net web application in that I have a radtreeview

<telerik:RadTreeView runat="server" ForeColor="Black" ID="RadTreeView1" DataSourceID="SqlDataSource4"
                            DataFieldID="UserCode"  DataTextField="Name" DataValueField="UserCode"
                             DataFieldParentID="SponsorCode" Skin="WebBlue">
                            <DataBindings>
                                <telerik:RadTreeNodeBinding Expanded="true" />
                            </DataBindings>
                        </telerik:RadTreeView>


Now what happening as i have so much data when I see output the some lines are coming in lefthand side and also treeview is expanding in right side at so
large..I want all the nodes should come in center and not in left and right direction and also lines should not be there
...Plz help


I am attaching image plz see
Plamen
Telerik team
 answered on 26 Aug 2011
2 answers
98 views
Hello,

I have a problem with RadGrid's DateTime Columns when the Page using the Grid is displayed in Safari 5.1 (and presumably also other versions of Safari). The Columns are several thousand pixels long.

I am using 2011 Q2 controls for ASP.NET.

I have set up a demonstration page, which includes basically the same Grid as my real web application does, and the error is present there aswell: http://paeppi.com/RadControlsWebApp2/Default.aspx

In Safari, this example looks like this: Screenshot

As you can see, there are basically no custom css styles on the page that might mess up the Grid.

The aspx source is:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="RadControlsWebApp2.Default" %>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 
<head runat="server">
    <title></title>
    <telerik:RadStyleSheetManager id="RadStyleSheetManager1" runat="server" />
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
        <Scripts>
            <%--Needed for JavaScript IntelliSense in VS2010--%>
            <%--For VS2008 replace RadScriptManager with ScriptManager--%>
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" />
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js" />
        </Scripts>
    </telerik:RadScriptManager>
    <script type="text/javascript">
        //Put your JavaScript code here.
    </script>
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
    </telerik:RadAjaxManager>
    <div>
     
            <telerik:RadGrid ID="RadGrid1" ShowGroupPanel="true" AllowFilteringByColumn="true"
            ShowStatusBar="True" runat="server" AllowPaging="True" AllowSorting="true"
            AllowCustomPaging="True" VirtualItemCount="100000" PageSize="25" Height="752px">
            <ClientSettings AllowDragToGroup="true" />
 
                <MasterTableView>
                <CommandItemSettings ExportToPdfText="Export to Pdf"></CommandItemSettings>
 
                <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
                </RowIndicatorColumn>
 
                <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
                </ExpandCollapseColumn>
 
                <EditFormSettings>
                <EditColumn FilterControlAltText="Filter EditCommandColumn column"></EditColumn>
                </EditFormSettings>
                    <PagerStyle AlwaysVisible="True" FirstPageToolTip="Erste Seite" LastPageToolTip="Letzte Seite" NextPagesToolTip="Weitere Seiten" NextPageToolTip="Nächste Seite" PagerTextFormat="Seite wechseln: {4} &nbsp;Seite <strong>{0}</strong> von <strong>{1}</strong>, items <strong>{2}</strong> to <strong>{3}</strong> of <strong>{5}</strong>." PageSizeLabelText="Anzahl je Seite:" PrevPagesToolTip="Vorige Seiten" PrevPageToolTip="Vorige Seite" />
                </MasterTableView>
 
                            <PagerStyle Mode="NextPrevAndNumeric" AlwaysVisible="True" BorderStyle="None" FirstPageToolTip="Erste Seite" PagerTextFormat="Zu Seite: {4} &nbsp;Seite <strong>{0}</strong> von <strong>{1}</strong>, items <strong>{2}</strong> to <strong>{3}</strong> of <strong>{5}</strong>." PageSizeLabelText="Anzahl je Seite:" VerticalAlign="Bottom"></PagerStyle>
 
                <FilterMenu EnableImageSprites="False"></FilterMenu>
 
                <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default"></HeaderContextMenu>
            </telerik:RadGrid>
 
    </div>
    </form>
</body>
</html>


The codebehind is:

namespace RadControlsWebApp2
{
    public partial class Default : System.Web.UI.Page
    {
 
        protected void Page_Load(object sender, EventArgs e)
        {
            RadGrid1.NeedDataSource += new GridNeedDataSourceEventHandler(RadGrid1_NeedDataSource);
        }
 
        void RadGrid1_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
        {
            using (govistasigsDataContext db = new govistasigsDataContext())
            {
                RadGrid1.VirtualItemCount = db.Users.Count();
                RadGrid1.DataSource = (from p in db.Users select new { p.ID, p.RegisterDate, p.LastLogin }).Skip(RadGrid1.PageSize * RadGrid1.CurrentPageIndex).Take(RadGrid1.PageSize).ToArray();
            }
        }
    }
}


I tried fiddling with Safari's developer tools a bit, but to no success so far.

Any help is appreciated.

Best Regards.
Jayesh Goyani
Top achievements
Rank 2
 answered on 26 Aug 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?