Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
165 views
Hi,

I created this simple RadEditor through code behind, set ToolBar through ToolsDefault.xml and set an external CSS files for styles to appear in "Apply Css Class" drop-down. But they don't appear in the drop down. It works when i create an editor in ".aspx" page. but with code behind the drop-down is empty.

 RadEditor htmlEditor = new RadEditor();  
 htmlEditor.ExternalDialogsPath = "~/EditorDialogs/";  
 htmlEditor.ToolsFile = "~/EditorDialogs/ToolsDefault.xml";  
 htmlEditor.CssFiles.Add("~/EditorDialogs/Test.css");  
 this.form1.Controls.Add(htmlEditor);  

Could you please help! I need to load styles from an external file and i am stuck.

thanks.
Dobromir
Telerik team
 answered on 21 May 2010
1 answer
118 views
I have a dropdown that dictates the color pallet. It will either be default or only black. I am trying to reset the color pallet. How can I do this on the javascript side?

I have tried
function resetInkColor() {  
    var colorPicker = $find('<%= rcpInkColor.ClientID%>');  
    colorPicker.set_preset="Default";
    colorPicker.set_preset("Default");  
} 

I get the error of "Object doesn't support this property or method. What is the correct syntax?
Tsvetie
Telerik team
 answered on 21 May 2010
9 answers
700 views
Hi

I'm trying to use this example to have a treeview inside a combobox, all inside a grid template.

http://demos.telerik.com/aspnet-ajax/treeview/examples/functionality/treeviewcombobox/defaultcs.aspx?product=treeview

From the example this code is used to get the conmobox:
            function nodeClicking(sender, args)  
            {  
                var comboBox = $find("<%= RadComboBox1.ClientID %>");  
 
                var node = args.get_node()  
 
                comboBox.set_text(node.get_text());  
 
                comboBox.trackChanges();  
                comboBox.get_items().getItem(0).set_value(node.get_text());  
                comboBox.commitChanges();  
 
                comboBox.hideDropDown();  
            } 

My problem is how do I get set the comboBox var with my set up.

This is also all in a Masterpage that add another layer of complexity.

To recap - I have Masterpage | Rag Grid | Edit Template | RadCombo box | RadTreeView.

Can anyone offer any help?

Andy
Andy Green
Top achievements
Rank 1
 answered on 21 May 2010
2 answers
85 views
Hi

I have an EditFormTemplate and in the FormTemplate I have 2 dropdowns (They are asp:dropdowns, not Rad ones) I can populate them with data from code behind but what I want to do is populate the second ddlist from a value from the first.

This is the first ddl markup

<

 

asp:DropDownList ID="ddlSite" runat="server" AutoPostBack="true" SelectedIndexChanged="UpdateLocation"></asp:DropDownList>

On ther server I get the UpdateLocation event

 

    Protected Sub UpdateLocation(ByVal sender As Object, ByVal e As System.EventArgs)  
 
 
        Dim ddlLocation As DropDownList = DirectCast(FindControl("ddlLocation"), DropDownList)  
        Dim mw As New CoreData  
        Dim mw_dt As DataTable = mw.LocationByParent(sender.selectedvalue)  
        If mw_dt.Rows.Count > 0 Then  
            With ddlLocation  
                .Items.Add(New ListItem("", 0))  
                .DataSource = mw_dt 
                .DataValueField = "LocationId" 
                .DataTextField = "LocationName" 
            End With  
        End If  
 
    End Sub 
The problem is that the value for the second dropdownlist is always nothingm the findcontrol is failing.

I have also tried the following to find the control:

 

Dim editedItem As GridEditableItem = CType(CType(sender, DropDownList).NamingContainer, GridEditableItem)

 

 

Dim ddlLocationt As DropDownList = CType(editedItem("ddlLocation").Controls(0), DropDownList)

 

 

How do I get a handle on the second DropdownList?

Andy

 

 

Andy Green
Top achievements
Rank 1
 answered on 21 May 2010
4 answers
134 views
Hello,
I have a simple page with telerik RadAjaxPanel and a RadComboBox. I also need the Ajax toolkit (ver 4) so I refer to the scripts (MicrosoftAjax.js etc). The combobox has autopostback enabled. The error is (when EnableScriptCombine="False"):

Line: 183
Error: Object doesn't support this property or method

If I remove the ajax toolkit script reference it works (or dont have autopostback on the combo), so what do I do wrong when I combine them?
Best regards, Petter.

<%@ Page Language="VB" AutoEventWireup="false" CodeFile="pf3.aspx.vb" Inherits="pf3" %> 
<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %> 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml">  
<head runat="server">  
    <title></title>  
</head> 
<body> 
    <form id="form1" runat="server">  
     
        <telerik:RadScriptManager ID="RadScriptManager1" Runat="server"   
            EnableScriptCombine="False"   > 
            <Scripts> 
            <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" /> 
            <asp:ScriptReference Assembly="System.Web.Extensions" Name="MicrosoftAjax.js" Path="~/Scripts/MicrosoftAjax.js" /> 
            <asp:ScriptReference Assembly="System.Web.Extensions" Name="MicrosoftAjaxWebForms.js" Path="~/Scripts/MicrosoftAjaxWebForms.js" /> 
        </Scripts> 
        </telerik:RadScriptManager> 
   
    <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server"     height="200px" width="300px">  
        <telerik:RadComboBox ID="RadComboBox1" Runat="server" AutoPostBack="True">  
            <Items> 
                <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem1"   
                    Value="RadComboBoxItem1" /> 
                <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem2"   
                    Value="RadComboBoxItem2" /> 
            </Items> 
        </telerik:RadComboBox> 
        </telerik:RadAjaxPanel> 
    </form> 
</body> 
</html> 
Petter Forss
Top achievements
Rank 1
 answered on 21 May 2010
2 answers
98 views
I have a custom calendar skin that I am using in the DatePicker control.  I call the stylesheet in the header, set the EnableEmbeddedSkins property to False, and enter the custom skin name in the Skin property.  When I run the application and open the calendar, the day row (SMTWTFS) is aligned to the right, which looks horrible.  If I move the stylesheet call into the body below the the scriptmanager, the calendar will display correctly.  It seems that the the default stylesheet is loading some styles after my custom styles and over-riding some of them them.  Is this a bug?  Thanks.
Trent
Top achievements
Rank 1
 answered on 21 May 2010
2 answers
100 views
For some reason it appears my internet explorer is rendering the telerik editor incorrectly. It used to work fine until I moved to VS 2010. Attached is a screen shot. Has anyone else had this issue? It does not seem to do it with other third party controls.
James Daresta
Top achievements
Rank 1
 answered on 21 May 2010
0 answers
315 views
Hi

I am doing one project in telrik.it's fine, But am face problem in flickering  in master page loading.so i want reduce flickering and post back.I want  loading  only content page.i want when   i click the tab loading only content page not total page please how to remove flickering .please help me.

i am using this code in header 
<meta http-equiv="Page-Enter" content="blendTrans(Duration=0.2)" />
    <meta http-equiv="Page-Exit" content="blendTrans(Duration=0.2)" />

this is my master page .please give me any solutions

thanks regards
shanker.B  
<%@ Master Language="C#" AutoEventWireup="true" CodeBehind="Default.master.cs" Inherits="TelerikComponentsWS.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"> 
<html xmlns="http://www.w3.org/1999/xhtml"> 
<head runat="server"> 
  <meta http-equiv="Page-Enter" content="blendTrans(Duration=0.2)" /> 
    <meta http-equiv="Page-Exit" content="blendTrans(Duration=0.2)" /> 
    <title></title> 
    <link rel="Stylesheet" href="css/styles.css" type="text/css" /> 
   
</head> 
<body> 
    <form id="form1" runat="server"> 
    <telerik:RadStyleSheetManager ID="RadStyleSheetManager1" runat="server" > 
    </telerik:RadStyleSheetManager> 
    <telerik:RadScriptManager ID="scm" runat="server" ScriptMode="Release"  > 
    
    </telerik:RadScriptManager> 
    <div style="height: 100%;" id="splitterContainer"> 
        <telerik:RadAjaxManager ID="radAjMan" runat="server" UpdatePanelsRenderMode="Inline" 
            DefaultLoadingPanelID="logPan"> 
            <AjaxSettings> 
                <telerik:AjaxSetting AjaxControlID="horMenu"> 
                    <UpdatedControls> 
                        <telerik:AjaxUpdatedControl ControlID="leftMenu" /> 
                        <telerik:AjaxUpdatedControl ControlID="horMenu" /> 
                    </UpdatedControls> 
                </telerik:AjaxSetting> 
               <telerik:AjaxSetting AjaxControlID="leftMenu"> 
                    <UpdatedControls> 
                        <telerik:AjaxUpdatedControl ControlID="leftMenu" /> 
                       
                    </UpdatedControls> 
                </telerik:AjaxSetting> 
                  <telerik:AjaxSetting AjaxControlID="btn_logout"> 
                    <UpdatedControls> 
                        <telerik:AjaxUpdatedControl ControlID="btn_logout" /> 
                        
                    </UpdatedControls> 
                </telerik:AjaxSetting> 
                
            </AjaxSettings> 
             
        </telerik:RadAjaxManager> 
         
        <telerik:radformdecorator id="RadFormDecorator2" DecoratedControls="all" runat="server" decorationzoneid="ZoneID2" 
            skin="Windows7" ControlsToSkip="Select"> 
        </telerik:radformdecorator> 
         <telerik:radformdecorator id="RadFormDecorator1" DecoratedControls="all" runat="server" decorationzoneid="ZoneID3" 
            skin="Windows7" ControlsToSkip="Select"> 
        </telerik:radformdecorator> 
       <%-- <telerik:RadWindowManager ID="radWin" runat="server"> 
            <Windows> 
                <telerik:RadWindow ID="defFacWnd" OffsetElementID='<%#lnk_def_facility.ClientID%>' 
                    OpenerElementID='<%#lnk_def_facility.ClientID%>' NavigateUrl="~/User/DefFacility.aspx" 
                    OnClientClose="onDefFacClose" runat="server"> 
                </telerik:RadWindow> 
            </Windows> 
        </telerik:RadWindowManager>--%> 
        <telerik:RadFormDecorator ID="rad_decorator" runat="server" DecoratedControls="all" ControlsToSkip="Select"> 
        </telerik:RadFormDecorator> 
        <telerik:RadSplitter ID="contentSplitter" runat="server" Height="100%" Width="100%" 
          VisibleDuringInit="false" OnClientLoaded="initSplitter" ResizeWithParentPane="false"> 
            <telerik:RadPane ID="navigationPane" runat="server" Width="190"> 
                <div style="margin: 5px;"> 
                 <br/> 
                    <asp:Image ID="Image2" runat="server" ImageUrl="~/img/company_logo.jpg" /> 
                     
                    
                    <br /> 
                  <%--  <asp:LinkButton ID="lnk_def_facility" runat="server"></asp:LinkButton>--%> 
                </div> 
                <telerik:RadPanelBar ID="leftMenu" runat="server" Width="180px"> 
                </telerik:RadPanelBar> 
                 <br/> 
                 <br/> 
                  <br/> 
                  
                <div > 
                <asp:Button runat="server" ID="btn_logout" Text="Logout"  CausesValidation="false" />   
                </div> 
            </telerik:RadPane> 
            <telerik:RadSplitBar ID="splitter" runat="server" CollapseMode="Forward" /> 
            <telerik:RadPane ID="contentPane" runat="server" MinWidth="400"> 
                <div style="margin: 5px;"> 
                  <div id="ZoneID4" style="right: auto"> 
                <fieldset width="100%" style="border-style: none; padding-right: inherit;"  align="right"> 
                    <asp:Image ID="Image1" runat="server"  
                        ImageUrl="~/img/studentdatasuite_header.jpg" />  
                    </fieldset> 
                    </div> 
                    <telerik:RadTabStrip ID="horMenu" runat="server" SelectedIndex="0" DataFieldID="module_id"> 
                        <DataBindings> 
                            <telerik:RadTabBinding TextField="module" ValueField="module_id" /> 
                        </DataBindings> 
                    </telerik:RadTabStrip> 
                    
                </div> 
                <div style="margin: 5px;"> 
                    <h2> 
                        <asp:Literal runat="server" ID="ltTitle"></asp:Literal></h2> 
                    <asp:ContentPlaceHolder ID="centerContent" runat="server"> 
                     
                    </asp:ContentPlaceHolder> 
                </div> 
                <div id="ZoneID3" style="right: auto"> 
                <fieldset width="100%" style="border-style: none; padding-right: inherit;"  align="center"> 
                    <p> Â© 2009 Sama IT Group. All rights reserved. 
                            <a target="_self" title="Home" href="http://www.samaitgroup.com/">Home</a>  
                            <a target="_self" title="Products" href="http://www.samaitgroup.com/products.html">Products</a>  
                            <a target="_self" title="Aboutus" href="http://www.samaitgroup.com/aboutus.html">Aboutus</a> 
                            <a target="_self" title="Support" href="http://www.samaitgroup.com/support.html">Support</a> 
                            <a target="_self" title="Contacts" href="http://www.samaitgroup.com/contactus.html">Contacts</a> 
                       </p> 
                    </fieldset> 
                    </div> 
                  
            </telerik:RadPane> 
        </telerik:RadSplitter> 
       
        <telerik:RadAjaxLoadingPanel ID="logPan" runat="server" IsSticky="true" Transparency="30" 
            Style="position: absolute; top: 0; left: 0; line-height: 60px; text-align: center; 
            z-index: 99;" Width="100%" Height="100%" BackColor="#B9CDF7"> 
            <%--<asp:Image ID="img" runat="server" Width="130px" Height="60px" ImageUrl="~/img/loading.gif" 
                Style="border: 0; margin-top: 70px;"></asp:Image>--%> 
        </telerik:RadAjaxLoadingPanel> 
      
                     
                     
                 
    </div> 
<telerik:RadScriptBlock runat="server" ID="RadScriptBlock1"> 
    <script type="text/javascript"> 
//        function onDefFacClose(oWnd) {            //get the transferred arguments 
//            var arg = oWnd.argument; 
//            if (arg) { 
//                var facName = arg.facName; 
//                $get(oWnd.get_openerElementID()).innerHTML = facName; 
//            } 
//        } 
        function initSplitter(sender, args)   
        {          
            sender.get_element().style.visibility = 'inherit';   
        }   
  
    </script> 
</telerik:RadScriptBlock> 
    </form> 
</body> 
</html> 
 
shanker bangari
Top achievements
Rank 1
 asked on 21 May 2010
1 answer
116 views
It is possible to have a context menu that will allow you to duplicate information from the row you are selecting the context menu from?
Shinu
Top achievements
Rank 2
 answered on 21 May 2010
2 answers
104 views

I have a grid with FormTemplate to insert and update items. Within template there are related comboboxes that need javascript to work (client side binded). Client script needs to find them first.

How can I in simple way find them in script? 

Pavlina
Telerik team
 answered on 21 May 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?