Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
113 views
I have a rad grid where the 2nd level of the hierachy has a tab control with two page views each of which has a radgrid on it.  I want to load the child grids server side manually (i.e. doing the read and binding myself).  Currently I'm trying to do this in the Item_Command event.  Is this the right event?  If so, how can I determine the key of the master grid row that is being expanded?  If not, what is the correct event to be able to do this?  I need the key in order to load the grids on the tabs.

Thanks

Chris
Pavlina
Telerik team
 answered on 23 Sep 2010
3 answers
108 views
hi I have a RadTreeView which I have bound to an XML string. All works good no issues. I am now trying to add a navigation URL so that when the user clicks on a node of the treeview It will open a window based on the navigation URL. How can I do this so that I can specify the URL in XML which I pass to the Tree View.

Thanks
Vinay
Veronica
Telerik team
 answered on 23 Sep 2010
3 answers
269 views
Hi,

I am using RadComboBox with WebServiceMethod. Why is it so that RadComboBoxContext doesn't contain ItemsPerRequest property.

<telerik:RadComboBox ItemsPerRequest="20" ..../>

I have also tried to manually add the ItemsPerRequest to the context (IDictionary) on the event OnClientItemsRequesting but i can't seem to find the propery ItemsPerRequest from javascript.

example code:

<telerik:RadComboBox ItemsPerRequest="20" OnClientItemsRequesting="onClientItemsRequesting" ..../>

//javascript
function onClientItemsRequesting(sender, eventArgs) {
var context = eventArgs.get_context();
        context["FilterString"] = eventArgs.get_text();
context["ItemsPerRequest"] = sender.ItemsPerRequest; // ? where can i find the property
}

Simon
Telerik team
 answered on 23 Sep 2010
3 answers
178 views

I have a webpage that has a label, radsplitter and radpane, lets call it PageHost. In the radpane I load a page by changing the ContentURL property, lets call this page PageChild.

If from PageChild inside the radpane, I want to get handle to the label on PageHost, how do I do that?

Dobromir
Telerik team
 answered on 23 Sep 2010
4 answers
177 views
I use RadControls for ASP.NET AJAX Q1 2010.

One of my aspx-pages contain two different usercontrols, which both
open up a radwindow after a postback/button-push.

What happens is that if I've opened one of the windows, and closed it,
it will REAPPEAR when I try to open the radwindow from the other
usercontrol.

So - open first radwindow (postback) => OK.
Open second radwindow (postback) => Both windows open.

The same thing happens when refreshing the browser - If I've
had, say, a dozen radwindows open, they will reappear one by one.

What is it that I've done wrong or forgotten?
Georgi Tunev
Telerik team
 answered on 23 Sep 2010
0 answers
145 views
Hai Telerik,

i have a Employee combo box, with in which i bind checkboxes dynamically with employee name as text . used Item Template to do this.
 
<telerik:RadComboBox ID="cmbEmployee" Height="150px" DropDownWidth="150px" DataTextField="employee_name"
                                                DataValueField="employee_name" runat="server" Skin="Office2007" Width="150px"
                                                TabIndex="8" HighlightTemplatedItems="True" meta:resourcekey="cmbTechnicianResource1">
                                                <HeaderTemplate>
                                                    <table style="font-family: Verdana; font-size: xx-small">
                                                        <tr>
                                                            <td>
                                                                Employee
                                                            </td>
                                                        </tr>
                                                    </table>
                                                </HeaderTemplate>
                                                <ItemTemplate>
                                                   <div onclick="stopProp(event)">
                                                    <asp:CheckBox ID="chk" runat="server" onClick="onClick(event)" Text='<%#  
DataBinder.Eval(Container.DataItem, "employee_name") %>' meta:resourcekey="chkResource2" />
                                                   </div>                                                            
                                                             
                                                </ItemTemplate>
                                                <CollapseAnimation Duration="200" Type="OutQuint" />
                                            </telerik:RadComboBox>

i learned multi selecting check boxes with in combo box from the forum.
My combo box is having 'Select All' check box as a first item and other combo box items(list of employees) as check boxes. Now when i check 'Select All' check box, all employees (check boxes) should be checked. And when i uncheck 'Select All'  check box, all employees must be unchecked. Also after unchecking 'Select All', i should be able to check selected employees. Finally, text of all checked check boxes (except 'Select All') should be set as text to Employee combo box.

My java script is as below,

function StopProp(e) {
            e.cancelBubble = true;
                        if (e.stopPropagation) {
                            e.stopPropagation();
                        }
        }
 
function onClick(e) {
            
            var combo = $find("<%= cmbEmployee.ClientID %>");
            var newText = "";
            var items = combo.get_items();
 
            for (var i = 0; i < items.get_count(); i++) {
                var item = items.getItem(i);
                var checkbox = item.get_element().getElementsByTagName("input")[0];
 
                if (item.get_text() != "Select All" && checkbox.checked) {
                    newText += item.get_text() + ", ";
                }
                if (item.get_text() == "Select All" && checkbox.checked == true) {
                    var newText1 = "";
                    newText = "";
                    for (var i = 0; i < items.get_count(); i++) {
                        var item = items.getItem(i);
                        var checkbox = item.get_element().getElementsByTagName("input")[0];
                        newText1 = item.get_text();
                        checkbox.checked = true;
                        if (newText1 != "Select All") {
                            newText += item.get_text() + ", ";
                        }
                    }
                }
                
            }
            combo.set_text(newText);
        }

Now the behavior is like,

1. When Click on 'Select All' All the employees are checked and text of those check boxes (employees) set as text to combo box. Now i am not able to uncheck employees.
2. when i uncheck 'Select All', now i am able to check or uncheck employees and corresponding checked employee name (check box text) is set to combo box.
3. Now i need to uncheck all the employees with unchecking 'Select All' check box. For this i have added the following code as another condition with in 'for' loop.


if (item.get_text() == "----Select----" && checkbox.checked == false) {
                                   var newText1 = "";
                                   newText = "";
                                   for (var i = 0; i < items.get_count(); i++) {
                                       var item = items.getItem(i);
                                       var checkbox = item.get_element().getElementsByTagName("input")[0];
                                       newText1 = item.get_text();
                                       checkbox.checked = false;
                                       newText = "----Select----";
                                   }
                               }

Now, when i check 'Select All' all the employees are checked and when i uncheck 'Select All' all the employees are unchecked. Setting text to combo box is also fine. But now i am not able to check/uncheck selected employees. How can i achieve this?
Please reply me.
james
Top achievements
Rank 1
 asked on 23 Sep 2010
1 answer
123 views
We've noticed that at some point recently all the ComboBoxes that use the Filter property have become case-sensitive. This is true for both StartsWith and Contains settings, and seems to be the opposite of what the documentation suggests (which states that Filter is case-insensitive). 

We've fairly recently upgraded to the Q2 Telerik release from Q1, and I think it may have been after this upgrade. 

I'm just wondering if this is a new default behaviour, and if so how do you override it to the previous case insensitive version, or if this is a bug? 

Our Telerik DLL version is 2010.2.713.40, using .NET 4. 

This is a slightly stripped down markup of one of the ComboBoxes which has this problem. 

<telerik:RadComboBox ID="Combo" runat="server" AutoPostBack="true" Skin="Windows7" AllowCustomText="true" DataSourceID="OurDS" EnableAutomaticLoadOnDemand="true" EnableVirtualScrolling="true" EnableLoadOnDemand="true" ItemsPerRequest="30" EnableItemCaching="true" Filter="Contains" ShowMoreResultsBox="true" DataTextField="TextField" DataValueField="ValueID"                         EmptyMessage="Search..." OnSelectedIndexChanged="Method_SelectedIndexChanged" Width="175px" />
Simon
Telerik team
 answered on 23 Sep 2010
1 answer
45 views
Hello,

We're still using Rad Editor 6.6.1.0 for .NET 2.0 and recent some browsers don't support some of the markup the editor generates. For example, setting the text alignment in table cells adds inline markup like align="right" and vAlign="top" to the <td> element. I have noticed that the latest release of Rad Editor uses inline CSS for this.

I know it's not likely, but my boss asked me to come and ask you guys if there is a patch to make our old Rad Editor render out CSS-based markup.

Kind regards,
Kristof
Rumen
Telerik team
 answered on 23 Sep 2010
1 answer
134 views
Hi,

How can I set an Empty Text when the RadCombo is loaded?

In the attached code, after the binding, The item "Mark" is automatically highlighted (but not selected, as I want).
My goal is to have, after the binding, no selected elements and an empty Text in the combobox.
The dropdown has to stay "read-only" (user cannot input text)

<form id="form1" runat="server">
<telerik:RadScriptManager runat="server">
</telerik:RadScriptManager>
<telerik:RadComboBox DataValueField="ID" EnableTextSelection="false"
    Skin="Default" DataTextField="Name" ID="RadComboBox1" runat="server" >
<ItemTemplate>
    <asp:CheckBox runat="server" ID="chk1"/>
    <asp:Label runat="server" ID="Label1" AssociatedControlID="chk1" Text='<%# Eval("Name") %>'></asp:Label>
</ItemTemplate>
</telerik:RadComboBox>
 
 
</form>
using System;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Configuration;
using System.Web.Security;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using Telerik.Web.UI;
using System.Web.UI.MobileControls;
using RadControlsWebApp1;
using System.Collections.Generic;
 
public partial class Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        List<Item> items = new List<Item>();
        items.Add(new Item() { Id = 1, Name = "Mark" });
        items.Add(new Item() { Id = 2, Name = "Jon" });
        items.Add(new Item() { Id = 3, Name = "Frank" });
 
        //RadGrid1.DataSource = items;
        if (!IsPostBack)
        {
            RadComboBox1.DataSource = items;
            RadComboBox1.DataBind();
        }
    }
 
}


How can I achieve this?

thanks.

Leo

Shinu
Top achievements
Rank 2
 answered on 23 Sep 2010
2 answers
136 views
Hi 


I'm trying to get access to the RadDatePicker and RadTimePicker from client-side code. I've read that I should use $find() function, which is shortcut for $findComponent(), in Sys.Application.  But I can't find it, to get/set date!  

Could you tell me what's the problem plese?  Can  jquery cause this problem?
John John
Top achievements
Rank 1
 answered on 23 Sep 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Andrey
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Andrey
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?