Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
122 views
When a child is unchecked, I need to recurse up the tree and uncheck the parents.  For some reason when I say parentNode = node.get_parent()  I can not call not then call parentNode.set_checked();  This seems very odd.  I am using a javascript debugger and it seems as though the get_parent() method disapears after the assignment to parentNode. 

Please help. 

This is the heart of what I have now (which is not working).

parentNode = node.get_parent();

 

while (parentNode != null)

 

{

    parentNode.set_checked(

false);  //error thrown here set_checked method not found.

 

    parentNode = parentNode.get_parent();
}



Thanks,
Ken
Shinu
Top achievements
Rank 2
 answered on 20 Nov 2008
1 answer
141 views
i have a usercontrol (Third Party Control (Flexcel)- Excel) for exporting the data in RadGrid to an Excel Sheet.
i have a RadPanelBar consisting of RadChart(Chart for the data in RadGrid)  and RadGrid,

i have applied Ajax setting for UserControl to RadPanelBar(consisting of RadChart and RadGrid).
on clicking the Export UserControl sometimes very rarely drawn RadChart image disappears, this happens very rarely in application deployed in US Servers and very rarely in our local server in India...

Please let me know the solution.
 
Thanks and Regards
Uday.M
 
Vladimir Milev
Telerik team
 answered on 20 Nov 2008
1 answer
110 views
Hi,

I am using a rad grid with pagination in opur application. I have a small question on retaining the grid pager in a particular scenario. Please help me.

I have set the grid PageSize to 10. I bound dataset with 20 records to the grid. Pager displays 2 pages for the user to view the records(10 records per page). Now if user changes the pagesize as 20 using the pager, then a single page will be displayed to the user with all 20 records in it. And pager will be not be displayed to the user anymore.
Now, if user want to set the PageSize back to 10, he/she cannot see the pager. Is it any property I am missing out to keep this pager?
Below is my grid definition:
<telerik:RadGrid ID="PrivateQueryDataGrid" runat="server" AllowPaging="true" PageSize="10" 
Skin="Web20" PagerStyle-Mode="NextPrevNumericAndAdvanced" OnItemCommand="PrivateQueryDataGrid_ItemCommand" 
AutoGenerateColumns="False" GridLines="None" OnNeedDataSource="PrivateQueryDataGrid_NeedDataSource">  
<MasterTableView DataKeyNames="QueryID" ItemStyle-CssClass="GridItem" HeaderStyle-CssClass="Grid" 
CssClass="Grid" AlternatingItemStyle-CssClass="GridAltItem" RetrieveAllDataFields="false"> <Columns> 
<telerik:GridBoundColumn DataField="QueryName" HeaderStyle-HorizontalAlign="Center" 
HeaderText="Query Name">  
</telerik:GridBoundColumn> 
<telerik:GridBoundColumn DataField="ReportName" HeaderStyle-HorizontalAlign="Center" 
HeaderText="Report Name">  
</telerik:GridBoundColumn> 
<telerik:GridBoundColumn DataField="FilterString" HeaderStyle-HorizontalAlign="Center" 
HeaderText="Filter String">  
</telerik:GridBoundColumn> 
<telerik:GridBoundColumn DataField="CreatedBy" HeaderStyle-HorizontalAlign="Center" HeaderText="Created By">  
</telerik:GridBoundColumn> 
</Columns> 
<RowIndicatorColumn> 
<HeaderStyle Width="20px" /> 
</RowIndicatorColumn> 
<ExpandCollapseColumn> 
<HeaderStyle Width="20px" /> 
</ExpandCollapseColumn> 
</MasterTableView> 
<ClientSettings EnablePostBackOnRowClick="true">  
<Resizing ClipCellContentOnResize="false" /> 
<Selecting AllowRowSelect="True" /> 
</ClientSettings> 
<FilterMenu EnableTheming="True">  
<CollapseAnimation Duration="200" Type="OutQuint" /> 
</FilterMenu> 
</telerik:RadGrid> 

Thanks in advance,
Nataraj
Princy
Top achievements
Rank 2
 answered on 20 Nov 2008
4 answers
244 views
 My Rad version is Q1 2008 , when I use RadDatePicker , there's always a error that : "onclick is not valid attribute of element DateInput" , even I copy code example , it still have a same problem ... Can somebody help me resolve this. Thanks !
My aspx code is below

<%@ Page Language="C#" AutoEventWireup="true"  CodeFile="Default.aspx.cs" Inherits="_Default" %> 
 
<%@ 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"> 
 
<html xmlns="http://www.w3.org/1999/xhtml" > 
<head runat="server"> 
    <title>Untitled Page</title> 
</head> 
<body> 
    <form id="form1" runat="server"> 
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server"> 
        </telerik:RadScriptManager> 
        <script type="text/javascript"> 
        function ToggleFirstPopup() 
        { 
            $find("<%= RadDatePicker1.ClientID %>").showPopup(); 
        } 
        </script> 
    <div> 
        <telerik:RadDatePicker ID="RadDatePicker1" runat="server" Culture="English (United States)" 
            SelectedDate="2008-11-19" Style="position: relative"> 
            <DatePopupButton Visible = "true" > </DatePopupButton> 
             
            <DateInput onclick = "ToggleFirstPopup()" DateFormat = "D"> 
             
            </DateInput> 
        </telerik:RadDatePicker> 
     
    </div> 
    </form> 
</body> 
</html> 
 
Shinu
Top achievements
Rank 2
 answered on 20 Nov 2008
3 answers
223 views
I was looking at this example:
http://demos.telerik.com/aspnet/prometheus/Calendar/Examples/DatePicker/CustomPopup/DefaultCS.aspx

It has this:

           <DateInput onclick="ToggleSecondPopup()" DateFormat="D">
            </DateInput>


I want to have the user pop up the calendar when they click the date input field.

but I tried this in codebehind:
 RadDatePicker1.DateInput.Attributes.Add("onclick", "PopupCalendar()")

And it doesn't work. Also, the DateInput.OnClick attribute doesn't exist.

How do I do this in codebehind?


My javascript is:

        <script type="text/javascript">
        function PopupCalendar()
        {
            $find("<%= Raddatepicker1.ClientID %>").showPopup();
        }
        </script>

thanks.

Shinu
Top achievements
Rank 2
 answered on 20 Nov 2008
2 answers
334 views
I have a RadEditor in a customer user control, i'm sure i have all properties set correctly but can't seem to get the RadEditor to load up my styles. For some reason, it seems to load the parent page styles even with the EditorCssFile property set.

RadEditor User Control

<%@ Control Language="C#" AutoEventWireup="true" CodeFile="RadEditor.ascx.cs" Inherits="Plugins.RadEditor" %> 
 
<telerik:RadEditor  
    ID="txtContentEditor" 
    Runat="server" 
    ToolbarMode="Default" 
    ToolsFile="~/App_Data/RadEditor/EditorTools.xml" 
    Width="100%" 
    Height="400" 
    Skin="Default" 
    EnableEmbeddedScripts="true" 
    EnableEmbeddedBaseStylesheet="true" 
    EnableEmbeddedSkins="true" 
    NewLineBr="false" 
    ContentFilters="ConvertToXhtml">  
      
    <CssFiles> 
        <telerik:EditorCssFile Value="/Skins/Plugins/EditorStyles.css" /> 
    </CssFiles> 
      
    <CssClasses> 
        <telerik:EditorCssClass Name="header1" Value="h1" /> 
    </CssClasses> 
      
    <Paragraphs> 
        <telerik:EditorParagraph Tag="<p>" Title="Normal" /> 
        <telerik:EditorParagraph Tag="<p class='Title'>" Title="Title" /> 
        <telerik:EditorParagraph Tag="<h1>" Title="Header 1" /> 
        <telerik:EditorParagraph Tag="<h2>" Title="Header 2" /> 
        <telerik:EditorParagraph Tag="<h3>" Title="Header 3" /> 
        <telerik:EditorParagraph Tag="<h4>" Title="Header 4" /> 
        <telerik:EditorParagraph Tag="<h5>" Title="Header 5" /> 
    </Paragraphs> 
 
    <ImageManager UploadPaths="~/Uploaded_Images/" ViewPaths="~/Uploaded_Images/" ImageEditorFileSuffix="*.gif,*.jpg,*.jpeg,*.png,*.img" SearchPatterns="*.gif,*.jpg,*.jpeg,*.png,*.img" MaxUploadFileSize="204800"  /> 
 
    <DocumentManager UploadPaths="~/Uploaded_Documents/" ViewPaths="~/Uploaded_Documents/" SearchPatterns="*.doc,*.txt,*.pdf,*.ppt,*.xls,*.rtf" MaxUploadFileSize="204800" /> 
 
</telerik:RadEditor> 

My Page with the user control attached.

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Content.aspx.cs" Inherits="EditorDialogs.Content" %> 
<%@ Register TagPrefix="uc1" TagName="RadEditor" Src="~/Plugins/RadEditor.ascx" %><?xml version="1.0" encoding="utf-8"?>  
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> 
 
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xml:lang="en">  
 
<head> 
 
    <title>Content</title> 
    <link href="/Skins/Plugins/EditorDialogs.css" rel="stylesheet" type="text/css" /> 
 
</head> 
 
<body> 
 
    <form id="form1" runat="server">  
 
    <asp:ScriptManager runat="server" ID="defaultScriptManager" EnablePartialRendering="true" ScriptMode="Release">  
        <CompositeScript ScriptMode="Release">  
            <Scripts> 
                <asp:ScriptReference Name="MicrosoftAjax.js" /> 
                <asp:ScriptReference Name="MicrosoftAjaxWebForms.js" /> 
            </Scripts> 
        </CompositeScript> 
    </asp:ScriptManager> 
 
    <h1>Content Manager</h1> 
      
    <p>You are currently editing page <asp:Label runat="server" ID="lblPageTitle" CssClass="Blue" />.</p> 
 
    <telerik:RadAjaxPanel runat="server" ID="StaticPanelEditor" LoadingPanelID="LoadingPanel">  
          
        <p runat="server" id="lblPageInfo" class="Success" visible="false" /> 
 
        <syntasso:RadEditor runat="server" ID="txtContentEditor" /> 
          
        <asp:Button runat="server" ID="btnPublish" CssClass="Button" Text="Publish" OnClick="btnPublish_OnClick" /> 
 
    </telerik:RadAjaxPanel> 
 
    </form> 
      
</body> 
 
</html> 

EditorStyles.css

html,body  
{  
    font-family: Arial, Helvetica, Sans-Serif !important;  
}  
 
h1,h2,h3,h4,h5  
{  
    font-family: Arial, Helvetica, Sans-Serif !important;  
    font-size: 21px !important;  
    font-weight: normal;  
    letter-spacing: 1px;  
    margin: 0 0 10px 0;  
    color: #00927b !important;  
}  
 
p  
{  
    font-size: 14px;  
    color: #383a3a;  
    margin: 50px 0 !important;  
}  
 
p.Title  
{  
    font-size: 14px;  
    font-weight: bold;  
    color: #e2007a;  
}  
 
ul {  
    font-size: 14px;  
    color: #383a3a;  
    letter-spacing: 0em;  
    text-indent: 25px;  
    margin-top: 8px;  
    margin-bottom: 5px;  
} 
Kevin Babcock
Top achievements
Rank 1
 answered on 20 Nov 2008
2 answers
220 views
I need to retrieve the RadMaskedTextBox through a Request.Form method.

I have found that there is a hidden input named something like "ctl00_InputName_text" that I can use, but the value that comes back include the input mask prompt and literals (ie "65656-____" for zip+4 mask).

Is there another hidden input that does not include the mask prompt and literals?
Kevin Babcock
Top achievements
Rank 1
 answered on 20 Nov 2008
8 answers
231 views
Hi,
How would i change the labels for the grid editor controls ?

What i am trying to change is the forecolor of a controls label.
I have successfully added a RequiredFieldValidator to a control within the grid editor, but i would like the label of the control to always be red.

Is this possible ? If so, please can you help (i'm sure you can !)

Many Thanks
Mark :-)
Steve Newbery
Top achievements
Rank 1
 answered on 19 Nov 2008
0 answers
139 views
I am developing a web app and was hoping to get some architecture advice. This application has 4 primary tabs and each tab has 2-5 sub-tabs. Each sub tab will represent a page of content that includes various contols (grids, trees, etc.). I am trying to figure out the best way to architect the use of these tabs in order to create the best possible performance and user experience.

Option 1: I can have a single web page and use the tabstrip conrol and multipage to display all the pages. To improve performance, I can load the pageviews and their content dynamically. 

    Pros: This will limit the initial loading time of the applicatoin as only the default sub-tab page will be loaded. Subsequent loadings can be done with Ajax to prevent postbacks. After a page has been loaded the first time, subsequent clicks to it will be almost instantaneous and they would be handled by the client-side abilities of the tabstrip.

    Cons: Each time a new sub-tab page is loaded, the viewstate will grow. So, each time I do something on one of the pages, it will require the loading of the viewstate for other pages which have nothing to do with what is going on on that particular page. Also, I have found that getting dynamically loaded controls to funciton well in more complext scenarios to be quite challenging.

Option 2: I can use the tabstrip and subtabs to load each page in a container, such as as splitter pane.
    
    Pros: Each page will be loaded from scratch, so the viewstate wil only be loaded for the particular page being displayed. Because each page will be loaded individually, the operation of the controls within them will be simpler (ie they won't depend on dynamic loading)

    Cons: Each loading of the pages will require the same amount of time since they will be loaded from scratch upon clicking on the tabstrip. Also, there will be no "memory". For instance if I change the sort order of a grid on one of the pages, and click to another page, when I click back, the grid will be re-initialized, because the page wil be loaded from scratch.

I'm not sure I can think of any other architectures off the top of my head as alternatives. Any advice about these or any others would be appreciated!
Albert Shenker
Top achievements
Rank 1
Veteran
Iron
 asked on 19 Nov 2008
3 answers
110 views
I have been working with a Microsoft developer directly over the last week. We were trying to determine why Visual Studio 2008 "hangs" for up to 10 seconds after clicking on controls within my page in Design mode of the IDE.

I'm developing a site using Visual Studio 2008, VB.Net and SQL 2005.

The page in question is a content page. The master page is fairly simple. It only contains a couple label controls, a radMenu and a breadcrumb.

The content page contains a set of drop-down lists populated using SQLDataSource controls. These appear at the top of the page within an HTML <table>. These drop-down are all linked as Control Parameters to a SQLDataSource that populates a GridView. (not the radGrid)

Users are able to select a row in the gridview making the gridview a master of other details.

Under the gridview I have a radTabStrip and of course matching radMultiPage / radPageView controls which encapsulate 8 separate DetailsView controls. (one in each PageView)

One of these DetailsViews has a radEditor control (simplified to have only 3 items in the options menu).

Also there are several ModalPopupExtender controls being used on the page as well. (From the Ajax Control Toolkit).

While in the Visual Studio 2008 IDE, editing this form in Design mode, when I click on any control within any PageView, Visual Studio 2008 (devenv.exe) eats up 50% CPU (I have a dual core, so that means 100% of one CPU) for up to 10 seconds.

I tried my best to prove to the Microsoft developer that it wasn't your controls. However, a simple test proved that it was.

I removed the radTabStrip, radMultiPage and radPageViews, as well as the radEditor control. Once I did that, the IDE performed as expected and was not "hanging" at all.

I do not consider this form I've designed (using a radTabStrip) "complex" or something out of the ordinary.

From our tests it appears that the 50% CPU occurs when the Design view is attempting to update the Source view and vice-versa. (It also occurs while in source view and just hitting the enter key on any line of code).

Again, no problems occur when Telerik controls are not used on the page.

My question is: Is Telerik aware of this flaw in the design of your component(s) and are you working to resolve it? If so, have you deteremined the exact cause? (e.g. too many properties, causing the IDE to load slower?)





Charles Forsyth
Top achievements
Rank 2
 answered on 19 Nov 2008
Narrow your results
Selected tags
Tags
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?