Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
333 views
I am using the RadTextBox with MultiLine enabled.  The issue i am having is that i need to determine whether or not there have been changes from what is being held in the database, and if there has been changes then display a warning message.  Chrome, Safari, Firefox all work fine; however, in Internet Explorer and Opera new lines are changed from  Line Feeds (\n) to a Carriage Return followed by a Line Feed (\r\n). Therefore, even if a person doesn't make changes to the RadTextBox, Internet Explorer/Opera will see the string coming from the database (the string with just \n's) different from what's in the RadTextBox (the string with \r\n's).  

I have attached images of what is being displayed, along with what is being seen in the RadTextBox (ContentEditor.Text) and what is being seen in the database (CurrentContent).  Also, below should be a snippet of the aspx code for my RadTextBox:

<telerik:RadTextBox runat="server" ID="ContentEditor" Height="200px" Width="580px" TextMode="MultiLine"
Wrap="true" ></telerik:RadTextBox>

Is there anyway to fix this, or is there a reason why this is happening?

Thanks again for the help,

- Pat
Pat
Top achievements
Rank 1
 answered on 28 Dec 2011
3 answers
110 views
hello,
Recently i have been working on radrecurrenece editor, i wanted to customize end by datepicker calendar how to do that , iam attaching image of the calendar to be customized ,please respond thanks.

regards,
madhukar
Peter
Telerik team
 answered on 28 Dec 2011
1 answer
205 views
Hello,
I am working on radcombobox and according to my requirement i have to aplly css to radcombobox so that it should look like the images  i attached below ,when notclicked and when clicked,is there any way to do that ,please reply soon thanks.

Regards,
madhukar.
Ivana
Telerik team
 answered on 28 Dec 2011
18 answers
357 views
Hello,

I have a page with a datepicker control as well as a textbox.  When the date changes in the datepicker, I would like to change the text in the textbox.  I do not want to postback during this process so I have ajaxified the datepicker control with the ajaxmanager.  The problem is that when I select a date, the page stops responding and I get the IE message "A script on this page is causing Internet Explorer to run slowly.  If it continues to run, your computer may become unresponsive.  Do you want to abort the script?"  How can this problem be resolved?  My code is below:

---------------------------------------------------------------------------

<

rad:RadAjaxManager ID="RadAjaxManager1" runat="server">

<AjaxSettings>

<rad:AjaxSetting AjaxControlID="dateWeekStartDate">

<UpdatedControls>

<rad:AjaxUpdatedControl ControlID="dateWeekStartDate" />

<rad:AjaxUpdatedControl ControlID="txtWeekEndDate" />

</UpdatedControls>

</rad:AjaxSetting>

</AjaxSettings>

</rad:RadAjaxManager>

<

div class="row">

<div class="titleColumn">

Date:

</div>

<div class="column">

<rad:RadDatePicker ID="dateWeekStartDate" runat="server" Skin="None" OnSelectedDateChanged="dateWeekStartDate_SelectedDateChanged">

<DateInput Skin="None" CssClass="calInput" AutoPostBack="true"></DateInput>

<PopupButton CssClass="calButton" ToolTip="" />

<Calendar runat="server" ID="calStart" CssClass="calendar" EnableNavigation="true" >

<TitleStyle CssClass="calTitle" />

<DayStyle CssClass="calDay" />

<CalendarTableStyle CssClass="calTable" />

</Calendar>

</rad:RadDatePicker>

</div>

</div>

<div class="row">

<div class="titleColumn">

Date:

</div>

<div class="column">

<asp:TextBox runat="server" ID="txtWeekEndDate" ReadOnly="true"></asp:TextBox>

</div>

</div>

-----------------------------------------------------------------------------------------------------------------------

protected

void dateWeekStartDate_SelectedDateChanged(object sender, Telerik.WebControls.SelectedDateChangedEventArgs e)

{

txtWeekEndDate.Text = dateWeekStartDate.SelectedDate.ToString();

}

------------------------------------------------------------------------------------------------------------------------

Any help would be greatly appreciated.

Thank you,

Jennifer

Richard
Top achievements
Rank 1
 answered on 28 Dec 2011
1 answer
131 views
Hi Support,

I have two Question: 
Q. 1 =>  I have a situation where I need only two way sorting that is Ascending OR Descending... 
In my grid if I click on column header it works like:

First Click : Ascending Order
Second Click: Descending Order
Third Click: Sorting Removed

I want on third click it should sort it again Ascending order and so on....
An example will be great help.

Q.2. =>  I saw  an example where you are handling 300,000 records in a grid that works at great speed. In that example you are binding data from some web service. 
http://demos.telerik.com/aspnet-ajax/grid/examples/client/caching/defaultcs.aspx

I have 700,000 records for a report and SQL Server 2008 as back-end. I am binding from code behind using DataSet. It is working but it is very slow... it took almost 45 seconds to retrieve data for one screen.

Can you suggest me how can I speed it up like your demo example.

Thanks
Milena
Telerik team
 answered on 28 Dec 2011
4 answers
175 views
Hi,
I have a radpanelbar with PersistStateInCookie="True". It's is populated dynamically in code behind. I want to write a javascript code to check if there is no level 0 item expanded then it expands the last level 0 item. I have written the following code:
function ExpandFirst() {
    var panelBar = $find("<%= _radpnlbarMenu.ClientID %>");
    if (panelBar) {
        var item = panelBar.get_expandedItem();
        if (panelBar.get_expandedItem() == null) {
            var items = panelBar.get_items();
            if (items.get_count() > 0)
                items.getItem(items.get_count() - 1).expand();
        }
    }
}
 
$(document).ready(function() {
    ExpandFirst();
});



<telerik:RadPanelBar OnItemDataBound="RadpnlbarMenuOnItemDataBound" runat="server" ID="_radpnlbarMenu" ExpandAnimation-Type="InQuart" ExpandAnimation-Duration="500" CollapseAnimation-Duration="500" CollapseAnimation-Type="InQuart" Height="250px" ExpandMode="FullExpandedItem" PersistStateInCookie="True">
    <DataBindings>
        <telerik:RadPanelItemBinding Depth="0" Expanded="true" />
    </DataBindings>
</telerik:RadPanelBar>

It works fine in Firefox but in IE the panelBar object is always null.
Is this the best way to do the trick?
Can you please help me?
Kate
Telerik team
 answered on 28 Dec 2011
5 answers
123 views
Hi,

       I want to export radgrid to excel..
     
      In that i have one column with hyperlink and i want to that hyperlink with href should be present in Excel also..

      Please give me Reply ASAp.

Thanks,
SANNIDHI
Andrey
Telerik team
 answered on 28 Dec 2011
4 answers
104 views
Part of the workflow of my application is that my RadMenu is on occasion disabled, and then re-enabled. On re-enable, the URLs of the top level menu items are corrupted. For example, I have:

            <telerik:RadMenuItem Text="Home" ToolTip="Home" Value="" NavigateUrl="~/home.aspx" />

as a top level menu item.

If I look at the source of the page, this is rendered as 

<a title="Home" class="rmLink rmRootLink" href="../home.aspx">


I then run my Javascript to disable, and then re-enable:

    function ShowMenu(enable)

    {

        var menu = $find("<%= OasisMenu.ClientID %>");

        if (enable)

            menu.enable();

        else

            menu.disable();

    }


at that point, the rendering becomes:

<a title="Home" class="rmLink rmRootLink" href="~/home.aspx" jQuery16405095697138168546="7">

and when I click on it it becomes:
http://localhost:11578/Personnel/~/home.aspx
well, it becomes a 404 page.

This only applies to the three menu items at the top level that are links. The second level menu items are fine.

I posted the whole menu in a previous menu problem question a couple of days ago, but can post again if it would be helpful (or I can put in a support ticket, if that would be helpful). Any fix? Any workaround? (Since it's just three items, I suppose there's some way I could save them and reset them in the Javascript?)

This is Telerik.Web.UI 2011.3.1115.40, by the way.



Velma
Top achievements
Rank 1
 answered on 28 Dec 2011
5 answers
920 views
Hi,

I'm working for a client that needs to display a list of programs in a grid and have a list of sub-programs under each program.  Those subprograms AKA locals need to have radio buttonlist, because the user can have the choice to select any options and update those options.

I have three datatables:
1. Program data
2. All locals
3. Userlocals
Please note that dt 2 & 3 need to be merged.  In order for the selectedvalue in the radio buttonlist to be selected (represents a user selection).

I'd like to know how to accomplish this.  This is what I have so far

HTML:
<telerik:RadGrid ID="rgMyGrid" runat="server" Skin="Office2007" AutoGenerateColumns="false">
            <MasterTableView CommandItemDisplay="Top" ShowHeader="true">
                <CommandItemTemplate>
                    <div style="padding: 5px;">
                        Below is a listing of programs for the selected client. You can add this user to
                        one or more programs by expanding the program node and selecting a localization.
                        You must select at least one program/localization.
                    </div>
                </CommandItemTemplate>
                <Columns>
                    <telerik:GridBoundColumn DataField="ProgramName" HeaderText="Programs" />
                    <telerik:GridButtonColumn CommandName="Delete" Text="Remove" UniqueName="RemoveColumn"
                        ButtonType="PushButton" />
                </Columns>
                <NestedViewTemplate>
                    <div style="width: 100%; padding-left: 10px;">
                        <asp:RadioButtonList runat="server" ID="rdoLocals"/>
                    </div>
                </NestedViewTemplate>
            </MasterTableView>
        </telerik:RadGrid>
        <telerik:RadTreeView ID="rtvProgramsLocals" runat="server" Skin="Outlook" Visible="false">
        </telerik:RadTreeView>

Here is what I have in the VB.NET code-behind

  If Not IsPostBack Then
  
            rgMyGrid.DataSource = LoadPrograms(100)
            rgMyGrid.DataBind()
  
   End If
  
Private Function LoadPrograms(ByVal ClientId As Integer) As DataTable
        'Dim p360programs As Programs = Nothing
        Dim programsDT As New DataTable("Programs")
        Dim localsDT As New DataTable("Locals")
        Dim userLocalDT As New DataTable("UserLocal")
        Dim localOptions As RadioButtonList
        'p360programs = New Programs(ConfigurationManager.ConnectionStrings("P360ConnectionString").ConnectionString)
        Dim i As Integer
        Dim j As Integer
        Dim programNode As RadTreeNode
        Dim localNode As RadTreeNode
  
        programsDT.Columns.Add("ProgramID", GetType(Int32))
        programsDT.Columns.Add("ClientID", GetType(Int32))
        programsDT.Columns.Add("UserID", GetType(Int32))
        programsDT.Columns.Add("ProgramName", GetType([String]))
        programsDT.PrimaryKey = New DataColumn() {programsDT.Columns("ProgramID")}
        programsDT.Rows.Add(New Object() {100, 100, 7628, "Internal Administration"})
        programsDT.Rows.Add(New Object() {106, 100, 7628, "TestProgram"})
        programsDT.Rows.Add(New Object() {107, 100, 7628, "TestProgram1"})
        programsDT.AcceptChanges()
  
        localsDT.Columns.Add("LocalizationID", GetType(Int32))
        localsDT.Columns.Add("ProgramID", GetType(Int32))
        localsDT.Columns.Add("LocalizationName", GetType([String]))
        localsDT.PrimaryKey = New DataColumn() {localsDT.Columns("LocalizationID")}
        localsDT.Rows.Add(New Object() {100, 100, "Setup Tool"})
        localsDT.Rows.Add(New Object() {105, 106, "MyLocal"})
        localsDT.Rows.Add(New Object() {106, 106, "MyLocal2"})
        localsDT.Rows.Add(New Object() {107, 107, "Local1a"})
        localsDT.AcceptChanges()
  
        userLocalDT.Columns.Add("LocalizationID", GetType(Int32))
        userLocalDT.Columns.Add("LocalizationName", GetType([String]))
        userLocalDT.PrimaryKey = New DataColumn() {userLocalDT.Columns("LocalizationID")}
        userLocalDT.Rows.Add(New Object() {100, "Setup Tool"})
        userLocalDT.Rows.Add(New Object() {105, "MyLocal From the secondary Table"})
        userLocalDT.AcceptChanges()
        'programsDT = p360programs.GetPrograms(ClientId)
  
        If programsDT.Rows.Count > 0 Then
            For i = 0 To programsDT.Rows.Count - 1
                If localsDT.Rows.Count > 0 Then
  
                    localsDT.Merge(userLocalDT, False, MissingSchemaAction.Ignore)
                    localOptions = New RadioButtonList
  
                    Dim gridRow As GridDataItem
  
                    For Each gridRow In rgMyGrid.MasterTableView.Items
  
                        localOptions = CType(gridRow.ChildItem.FindControl("rdoLocals"), RadioButtonList)
  
                        For j = 0 To userLocalDT.Rows.Count - 1
                            localOptions.Items.Add(New ListItem(localsDT(j)("LocalizationName"), localsDT(j)("LocalizationID")))                            
                        Next
  
                        ' add the radio button to the localization radtree node
                        localNode = New RadTreeNode()
                        localNode.Controls.Add(localOptions)
  
                        ' add the localization node to the program node
                        programNode = New RadTreeNode(programsDT.Rows(i)("ProgramName"))
                        programNode.Nodes.Add(localNode)
  
                        ' add the program node to the tree view control
                        rtvProgramsLocals.Nodes.Add(programNode)
  
                    Next
                      
  
                End If
  
            Next
  
        End If
          
        Return programsDT
  
    End Function

I've also attached a snapshot of what I'm trying to achieve.

Thanks,
Andrey
Telerik team
 answered on 28 Dec 2011
1 answer
137 views
Hai,

I have a radtabstrip with 4 tabs. Each tab contains one grid. I have to export the data on these 4 grids to different formats like pdf, excel etc. on clicking a "Print Report" button on the page. Is there any way to this? Its very urgent. Plz help.

Thanks,

Regeesh
Andrey
Telerik team
 answered on 28 Dec 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?