Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
193 views
Dear Telerik,

I am using a RadGrid with as custom data entry form and both are related only when the user clicks a link in the grid's row that fills up the Data enrty form with the row values. All manual. Now, this link column is actually this:

<telerik:GridTemplateColumn HeaderText="" UniqueName="EditColumn">
    <ItemTemplate>
        <asp:LinkButton CommandName="Edit" ID="LinkButtonEdit" runat="server">
            <asp:Image ID="ImageEdit" runat="server" ImageUrl="~/Images/Grid/Edit.gif" AlternateText="Edit" /></asp:LinkButton>
    </ItemTemplate>
</telerik:GridTemplateColumn>  

Everything works fine but upon clicking the link to edit, the grid row drops and shows a bit of it's built in edit form. I need to disable that.
Rajendran
Top achievements
Rank 1
 answered on 19 Jul 2013
1 answer
130 views
I have an instance where i need to call some javscript from my code behind file, and when I do, no other fucntions work on the page anymore.  My radmenu no longer works and all the ajaxtool kit stuff i have operating no longer work as well.  I put everything in a radScriptBlock but the same result.  how can I resolve this problem.  This command does nothing with the menu system, it just opens up a div if a value equals 1.  I need to call in code behind only in certain instance but it disables everything else and should not.


If myDataTable.Rows.Count > 0 Then
           If myDataTable.Rows(0)(2) = "True" Then
               FILLDDL() 'Fill the drop down lists
               rblReported.SelectedValue = 1
               ScriptManager.RegisterStartupScript(Me.Page, GetType(String), "OpenDiv", "OpenDiv();", True)
           Else
               rblReported.SelectedValue = 0
           End If
 
       Else
 
       End If
 
 
 
function OpenDiv() {
                   var rbl = document.getElementById("<%=rblReported.ClientID%>");
                   var radios = rbl.getElementsByTagName("input");
                   var div = document.getElementById("Recruited");
                   var forms = document.getElementById("printform");
                   var Recheader = document.getElementById("RecInfo");
                   var Selval
                   for (var i = 0; i < radios.length; i++) {
                       if (radios[i].checked) {
                           Selval = radios[i].value;
                           if (Selval == 1) {
                               div.style.display = "inline";
                               forms.style.display = "inline";
                               Recheader.style.display = "inline";
                           }
                           else if (Selval == 0) {
                               div.style.display = "none";
                               forms.style.display = "none";
                               Recheader.style.display = "none";
                           }
                       }
                   }
               }

Dimitar Terziev
Telerik team
 answered on 19 Jul 2013
6 answers
829 views
How can I set/change the text of a column header on the client in response to a client-side event?  I would expect a GridTableView.set_columnHeaderText() or GridColumn.set_headerText(), but I don't see any methods like this?
Daniel
Telerik team
 answered on 19 Jul 2013
1 answer
179 views
Hey Guys.
I'm having a silly problem with updating the radlistbox on buttonclick.

can you give me a hint.

Thnx in advance

------.aspx------
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="prova.aspx.cs" Inherits="Pages_prova" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<!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>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    <asp:ScriptManager runat="server" ID="scriptMgr1">
        </asp:ScriptManager>
        <table>
            <tr>
                    <td align="left">
                        <telerik:RadListBox runat="server" ID="RL_PagesSource" Height="180px" Width="200px" ></telerik:RadListBox>
                    </td>
                    <td valign="top" align="center">
                    <br />
                        <telerik:RadButton ID="RB_PLeft" runat="server" Text=" > " Width="40px"
                            onclick="RB_PLeft_Click" SplitButtonCssClass=""
                            SplitButtonPosition="Right" ></telerik:RadButton><br /><br />
                        <telerik:RadButton ID="RB_PRight" runat="server" Text=" < " Width="40px"
                            SplitButtonCssClass="" SplitButtonPosition="Right" ></telerik:RadButton><br /><br />
                        <telerik:RadButton ID="RB_PLAll" runat="server" Text=" >> " Width="40" ></telerik:RadButton><br /><br />
                        <telerik:RadButton ID="RB_PRAll" runat="server" Text=" << " Width="40" ></telerik:RadButton><br /><br />
                    </td>
                    <td style="padding-left:30px;" align="left">
                        <telerik:RadListBox runat="server" ID="RL_PageDestination" Height="180" Width="200"
                AutoPostBack="True" onselectedindexchanged="RL_PageDestination_SelectedIndexChanged"></telerik:RadListBox>
                    </td>
            </tr>
        </table>
    </div>
     
    <telerik:RadAjaxManager runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="RB_PLeft">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="RL_PagesSource" />
                    <telerik:AjaxUpdatedControl ControlID="RL_PageDestination" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>
     
    </form>
</body>
</html>


-----.aspx.cs----
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Telerik.Web.UI;
 
public partial class Pages_prova : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            RL_PagesSource.Items.Add(new RadListBoxItem("aaaa", "asdf"));
            RL_PagesSource.Items.Add(new RadListBoxItem("aasdf", "asdf"));
            RL_PageDestination.Items.Add(new RadListBoxItem("aasasdfadf", "asdf"));
        }
    }
    protected void RB_PLeft_Click(object sender, EventArgs e)
    {
        if (RL_PagesSource.Items.Count == 0 || RL_PagesSource.SelectedItem == null)
        {
        }
        else
        {
            RadListBoxItem it = new RadListBoxItem();
            it = RL_PagesSource.SelectedItem;
            RL_PageDestination.Items.Add(new RadListBoxItem(it.Text, it.Value));
             RL_PageDestination.DataBind();
            // RL_PagesSource.SelectedItem.Remove();
            // RL_PagesSource.DataBind();
        }
    }
    protected void RL_PageDestination_SelectedIndexChanged(object sender, EventArgs e)
    {
 
    }
}
Bozhidar
Telerik team
 answered on 19 Jul 2013
1 answer
79 views
I have a collapse of 1000 set on each context menu.  The menu will not hide until I click either on a link in the context menu or somewhere else on the tree page. The collapse time doesn't make a different.  (i.e. setting it to 1)
Kate
Telerik team
 answered on 19 Jul 2013
2 answers
127 views
Hi,
Here I have 2 problems ( one relatively simple, one sticky)

1 - The small "export to Excel" button in CommandItemSettings (ShowExportToExcelButton="true") it doesn't export anything, just refreshes the grid ( not the page) and makes the command line disappear, any ideas ? I also have a button export to excel which call the radgrid.export to excel command and exports the grid to excel. So I gues sIm missing some setting.

2 ( the sticky one) now the above grid configuration has a sqldatasource assigned to it. Ideally When the page is loaded for the first time I would like to display the grid but with no data-source ( basically it wont be visible) and then after some user input and doing a post back I go:

Grid.DataSource = result;
Grid.DataBind();

And the grid is built. But then when I try to export to excel I get an empty excel sheet, and after some testing it has to do something with not having that sql outsource initially. is there a way around this ?
regards, Neil
Neil
Top achievements
Rank 1
 answered on 19 Jul 2013
1 answer
181 views
Hi,

I trying to bind a dropDownColumn to a class property as Enum and the value in itemDataBound always nbsp. When i bind with BoundColumn it's ok, i see the value of the enum.

If i change the class property to integer, the dropDownColumn displayed correctly, but i want to keep the class property as enum.  

Any workaround for this?

'Do not work
Public class XYZ
    Public Property Status as StatusEnum
End Class
 
Public Enum StatusEnum as Integer
    Enabled = 0
    Disabled = 1
End Enum
 
'Work
Public class XYZ
    Public Property Status as Integer
End Class

ty
Antonio Stoilkov
Telerik team
 answered on 19 Jul 2013
1 answer
127 views

We are using SPRadEditor with Telerik.Web.UI version 2013.1.417.35. The Rad editor is declare using the below statement

<telerik:SPRadEditor ID="rtxtDetail" runat="server" Skin="Office2007" Width="100%" ToolbarMode="Default" ContentFilters="None" StripFormattingOptions="NoneSupressCleanMessage">

 

But the Toolbar is not getting fixed to the top of the control. Could you please help to provide a fix for this issue?

Thank you

 
Slav
Telerik team
 answered on 19 Jul 2013
1 answer
283 views
My RadGrid  bonded to a list collection, but bonded no to all fields. Is there any way to get another field from DataMember bonded to exact row which user has selected.
Radoslav
Telerik team
 answered on 19 Jul 2013
3 answers
122 views
Hi

I have a radtreeview which is used for a directory structure/file list viewer, and there is a problem when folders are collapsed.

When I have folder (node) A, with subfolder B (child node), if I expand folder A node in the tree and then click on folder B child node, the files are displayed in my content pane correctly. However, once subfolder B node is selected, if I then collapse folder A (parent folder), the tree node collapses correctly, however the content view (list of files) is also refreshed to those contained in the root node. I want to prevent this redirect, and have the content view unchanged (same behaviour as in windows file explorer). I've had a look around and it seems like the OnClientNodeCollapsing is where I need to make the fix, but here I'm only using the default behaviour. And I don't want to disable the collapse itself in the tree, only the redirect in the content.

I'd appreciate any help, thanks
Bozhidar
Telerik team
 answered on 19 Jul 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Dean
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Emil
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Dean
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Emil
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?