Telerik Forums
UI for ASP.NET AJAX Forum
6 answers
250 views

I haven't used the slider control before, so hopfully I am missing something simple. First,
using the follwing code, the slider value are not displayed: 

<telerik:RadSlider id="RadSlider1" runat="server" Height="95px"

 

 

ItemType="Tick" Length="300" MaximumValue="5" MinimumValue="1" Value="3" Width="400px" Skin="Windows7" TrackPosition="TopLeft" >

 

 

 

</telerik:RadSlider>


Thanks for you help.

 

Niko
Telerik team
 answered on 12 Apr 2011
3 answers
195 views
Hello,

I have a page that pops up a RadWindow.  Then the page pops up a radconfirm.  I want the radconfirm to appear over the RadWindow, but it appears beneath the RadWindow.  Is there anyway to give the radconfirm a higher z-index?

Thanks.
Svetlina Anati
Telerik team
 answered on 12 Apr 2011
3 answers
234 views
Quick question - I've been trying to figure out how to horizontally align these columns of a simple instance of RadCalendar using 100% width and inside of a fixed width div.

Image: http://i.imgur.com/ksOfZ.jpg

Code:
<div style="width:400px; vertical-align:top;">
         
       <telerik:RadCalendar ID="RadCalendar1" runat="server" AutoPostBack="true" Width="100%"
               PresentationType="Preview" DayNameFormat="Short" ShowRowHeaders="false" ShowOtherMonthsDays="true"
               EnableMultiSelect="false" UseRowHeadersAsSelectors="false" UseColumnHeadersAsSelectors="false"
               OnDayRender="RadCalendar1_DayRender" OnPreRender="RadCalendar1_PreRender">
           <DayStyle HorizontalAlign="Center" />
           <SpecialDays>
               <telerik:RadCalendarDay Repeatable="Today" Date="" ItemStyle-CssClass="rcToday" />
           </SpecialDays>
       </telerik:RadCalendar>        
 </div>

Appreciate any help.  Thanks.

-- Mike
Tsvetina
Telerik team
 answered on 12 Apr 2011
1 answer
59 views
Hello

I am implementing the RadToolTip and I have a senary quite common in systems today. I want to register as a User is in a textbox the tootltip shows a message about that field, then assigns an onclick event ShowEvent so that when users click on the textbox the message appears, but when we navigate between fields by pressing "Tab" sailed in this field when the tooltip does not open, so it must use an event OnFocus.
But my need is to use the two behaviors OnFocus and OnClick events, how could I do this? Is it possible?
Svetlina Anati
Telerik team
 answered on 12 Apr 2011
2 answers
136 views
Hello,

I have a Treelist that binds data that is not more then 1 level deep (Parent and 0 or 1 child). Now I have a button bind to each itemrow. What I want is that only the parentitem show the button (not the childitem). Is there a way in the ItemDataBound event to determine is a item is the parentnode (hasParent property) so I can only show the buttons for the parentitems?

Thanks in advance.

Kind regards,

Patrick
Patrick
Top achievements
Rank 1
 answered on 12 Apr 2011
5 answers
91 views
I have had this happen to me a few times now. Sometimes I'll add radtextboxes to a page and they won't show up at all. I can copy the code ver batum into a new differently named page, and they show just fine. I was just wondering if you have heard of this issue or if you think it's something with VS. I can say I have these in a page that has a masterpage with a radpanel on it. I can send some code if you like, I just don't know how much help it would be because like I said, if you copy and paste it to another page, it works fine. Any thoughts? I know this is probably the worst question to ask you to troubleshoot ever :)
Web Services
Top achievements
Rank 2
 answered on 12 Apr 2011
9 answers
272 views
I would like to use the RadMaskedTextBox in the following scenario:

My user has a multiline textbox in which he can enter text. This text has a maximum length per line and
must match certain criteria. In this  case it can be any character. When I set the text property of my
maskedtextbox the only thing that appears is my mask. I already tried to set the defaultmask, but when
the user clicks the textbox the default mask is applied. How  should I use the RadMaskedTextBox.
The code I am using is posted below

<%@ Page Language="C#" AutoEventWireup="true"  CodeFile="Default.aspx.cs" Inherits="_Default" %>
<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
 
<!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>
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server" />
        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" />
         
        <telerik:RadMaskedTextBox
            Width="300px"
            Height="80px"
            ID="RadMaskedTextBox1"
            runat="server"
            Label="Masked"
            TextMode="MultiLine"
            Mask = "aaa\r\naaa"
            TextWithLiterals = "123\r\n456"
            />
         
        <br />
        <telerik:RadTextBox
            Width="300px"
            Height="80px"
            ID="RadTextBox1"
            runat="server"
            Label="Normal"
            TextMode="MultiLine"
            Text = "123 456"
        />
    </div>
    </form>
</body>
</html>
Radoslav
Telerik team
 answered on 12 Apr 2011
1 answer
91 views
Hi ALL,

I've a combo with treeview for department selection. I want to use combo load on demand capability to filter that treeview, so I'll display all departments which contains entered text. I managed to sign to OnItemsRequest event to search my data source and repopulate that treeview.

But, as that treeview required OnClientNodeClicking event to display department full name ("parent > parent > parent > this"), after postback this message shows up:

Script control 'hierarquia' is not a registered script control. Script controls must be registered using RegisterScriptControl() before calling RegisterScriptDescriptors(). Parameter name: scriptControl

I tried to add RegisterWithScriptManager="FALSE" on treeview and register that client event manually with no success. How should I proceed?

So far I have this code snippets (some code removed):

<telerik:RadComboBox runat="server" ID="selecao" Width="450" AutoPostBack="true"
    LoadingMessage="Loading..." EmptyMessage="Expanda a hierarquia e selecione..." 
    OnClientDropDownOpened="OnClientDropDownOpenedHandler" EnableLoadOnDemand="true"
    MinFilterLength="3" OnInit="selecao_Init" OnItemsRequested="selecao_ItemsRequested" 
    OnClientItemsRequested="OnClientItemsRequested">
    <Items>
        <telerik:RadComboBoxItem Text="" Value="0"/>
    </Items>
    <ItemTemplate>
        <telerik:RadTreeView runat="server" ID="hierarquia" Width="300" 
            RegisterWithScriptManager="FALSE" 
            OnNodeExpand="hierarquia_NodeExpand" OnNodeClick="hierarquia_NodeClick"
            OnClientNodeClicking="nodeClicking" Skin="Default" CausesValidation="false" />
    </ItemTemplate>
</telerik:RadComboBox>

        protected void selecao_Init(object sender, EventArgs e)
        {
            if (this.Hierarquia.Nodes.Count == 0)
            {
                RadTreeNodeCollection parent = this.Hierarquia.Nodes;
                // load data
             }
 
            #region ClientScriptBlock
 
            ScriptManager.RegisterClientScriptBlock(thistypeof(FiltroGenerico), "FiltroGenerico"@"
 
                function nodeClicking(sender, args) {
                    var comboBox = $find(sender._clientStateFieldID.substring(0, sender._clientStateFieldID.length - 26));
                    var node = args.get_node()
 
                    var fullname = '';  // display full treename as requested
                    var pnode = node;
                    while(pnode != null && pnode.get_text != null)
                    {
                        fullname = ' > ' + pnode.get_text() + fullname;
                        pnode = pnode.get_parent();
                    }
                    fullname = fullname.substr(3)
 
                    comboBox.set_text(fullname);
                    comboBox.trackChanges();
                    comboBox.get_items().getItem(0).set_text(fullname);
                    comboBox.commitChanges();
 
                    comboBox.hideDropDown();
                    comboBox.attachDropDown();
                }
 
                function StopPropagation(e) {
                    if (!e)  e = window.event;
                    e.cancelBubble = true;
                }
 
                function OnClientItemsRequested(sender, eventArgs) {
                    var tree = sender.get_items().getItem(0).findControl('hierarquia');
tree.add_nodeClicking(nodeClicking);
                }
 
                function OnClientDropDownOpenedHandler(sender, eventArgs) {
                    var tree = sender.get_items().getItem(0).findControl('hierarquia');
                    var selectedNode = tree.get_selectedNode();
                    if (selectedNode) {
                        selectedNode.scrollIntoView();
                    }
                }"true);
 
            #endregion
        }

Dimitar Terziev
Telerik team
 answered on 12 Apr 2011
0 answers
89 views
Hi,

I am working on WPF Windows application and using Telerik controls.

I have a Stack Panel and inside the stack panel I have two RadGridView controls.

I want to export the entire data to Excell.

How do I achive this.

Is there any sample code available or any can any one here help me with a sample to fix this issue.

Any quick solution will be highly appreciated.

Thanks & Regards,
Hirak
hirak
Top achievements
Rank 1
 asked on 12 Apr 2011
1 answer
648 views
How do I access the Radscriptmanager located in my master page from my content page.

We have been having lots of problems with Response.Redirect because of Ajax Requests, and I found an article on your site that indicated that you should use RadAjaxManager.Redirect. To do so, I need to determine if the postback is an ajax postback, which I think is done like this:
scriptManager.IsInAsyncPostBack

But I can't figure out how to get to the script manager tag in the content page.

protected void RadGrid1_ItemCommand(object source, GridCommandEventArgs e)
{
    if (e.CommandName.ToUpper() == "SELECT" || e.CommandName.ToUpper() == "SELECTNEWWINDOW")
    {
        GridDataItem item = RadGrid1.MasterTableView.Items[e.Item.ItemIndex];
        string encryptedVal = Cryptography.Encrypt(item["AssetNumber"].Text);
        if (e.CommandName.ToUpper() == "SELECT")
            Response.Redirect(string.Format("~/Client/Asset/?id={0}", encryptedVal));
        if (e.CommandName.ToUpper() == "SELECTNEWWINDOW")
            Helper.RedirectPage(Page, GetType(), string.Format("~/Client/Asset/?id={0}", encryptedVal), true);
    }
}

I am doing this right now, but would like to do this by using the RadAjaxManager.Redirect.
I am also using a RadAjaxManager Proxy, and don't see a redirect method for the proxy.

public static void RedirectPage(Page page, System.Type type, string url, bool openInNewWindow)
{
    string urlResolved = page.ResolveUrl(url);
    if (!openInNewWindow)
    {
        ScriptManager scriptManager = ScriptManager.GetCurrent(page);
        bool isPartialPagePostback = false;
        if (scriptManager != null && scriptManager.IsInAsyncPostBack)
            isPartialPagePostback = true;
        if (isPartialPagePostback)
            ScriptManager.RegisterStartupScript(page, type, "''", "window.location.href='" + urlResolved + "'",
                                                true);
        else
            HttpContext.Current.Response.Redirect(url);
    }
    else
    {
        ScriptManager.RegisterStartupScript(page, type, "''",
                                            "window.open('" + urlResolved +
                                            "', '', 'height=600,width=800,scrollbars=yes,resizable=yes,location=yes')",
                                            true);
    }
}
Cori
Top achievements
Rank 2
 answered on 12 Apr 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?