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

I've created a custom toolbar button wich paste a vertical buttonlist in the editor. the buttonlist in nested in a 3x3 table. After pasting it i want to select the table by using the setActive() method. This is not working. Is it possible to get it work.
editor.pasteHtml(verticalRadioBuutonListAsHtml, commandName);  
var insertedElem = editor.get_document().getElementById(id);  
if (insertedElem) {  
        if (insertedElem.setActive) {  
            insertedElem.setActive();  
        }  
    } 
Other elements do work this way.

Gerco
Dobromir
Telerik team
 answered on 23 Feb 2010
9 answers
1.0K+ views
Hello,
I am using the licenced copy of the MOSS RAD Editor webpart. By default it shows the font size from 1 to 7. We would like to give font size start from 10 to 14 like the word. Please let me know how to do this. I tried by giving the font size on the tools file but its not working.

Regards,
Sudeep
Stanimir
Telerik team
 answered on 23 Feb 2010
1 answer
100 views
Hi all... I am trying to paint borders on marked zones, and leave the fills empty, to basically just show the threshold borders (max and min) for my series.

I am creating the marked zones programatically, and it is shading my graph, but it won't paint the borders, and I can't tell what I'm doing wrong. Here is my code:

        With chart.PlotArea 
            .MarkedZones.Clear() 
            Dim mz As TC.ChartMarkedZone 
            For Each dr As DataRow In Thresholds.Rows 
                mz = New TC.ChartMarkedZone(CStr(dr("NAME"))) 
                With mz 
                    .ValueStartY = dr.NullOf("MINVAL", min) 
                    .ValueEndY = dr.NullOf("MAXVAL", max) 
 
                    .Appearance.Border.Width = 2 
                    .Appearance.Border.Color = Drawing.Color.Red 
                    .Appearance.Border.PenStyle = Drawing.Drawing2D.DashStyle.Solid 
                    .Appearance.Border.Visible = True 
 
                    .Label.TextBlock.Text = .Name 
                    .Label.TextBlock.Visible = True 
 
                    .Visible = True 
                End With 
                .MarkedZones.Add(mz) 
            Next 
        End With 

And here is a the image that is being rendered. As you can see, it is adding the zones, and adding the labels, but it is refusing to paint the borders. (Ultimately they'd have different colors, but just all Red for now for testing.

generated output image

I am using version 2009.03.1208.35.
Ves
Telerik team
 answered on 23 Feb 2010
7 answers
251 views

[UPDATE]  I have attached an image highlighting the error.

THanks.

[Original message below] 

I am using the Inline Edit Mode of the radgrid.  When I enter Edit mode, the images for the control cannot be located.  For example, when I click the "Add New Record" link,  the "BreakStartTime" control displays "Open the time view popup" instead of showing the image for the time picker. 

Here is a code snippet:

<MasterTableView DataKeyNames="SchedNbr" HierarchyLoadMode="ServerOnDemand" Name="MainList"     
Width="95%" CommandItemDisplay="Bottom" InsertItemDisplay="Top" EditMode="InPlace"     
EditItemStyle-BackColor="BurlyWood">     
<Columns>    
    <telerik:GridBoundColumn UniqueName="Descript" SortExpression="Descript" HeaderText="<% $Resources:PageControls, Description %>" DataField="Descript" MaxLength="60" />     
    <telerik:GridNumericColumn UniqueName="BreakDuration" SortExpression="Duration" HeaderText="<% $Resources:PageControls, Duration %>" DataField="BreakDuration" NumericType="Number" MaxLength="3" />   
    <telerik:GridDateTimeColumn PickerType="TimePicker" UniqueName="BreakStartTime" HeaderText="<% $Resources:PageControls, StartTime %>" DataField="BreakStartTime" DataFormatString="{0:t}" />   
    <telerik:GridDateTimeColumn PickerType="TimePicker" UniqueName="BreakEndTime" HeaderText="<% $Resources:PageControls, EndTime %>" DataField="BreakEndTime" DataFormatString="{0:t}" />     
    <telerik:GridEditCommandColumn UpdateText="Update" UniqueName="EditCommandColumn"    
ButtonType="ImageButton" EditImageUrl="~/Images/icon_edit_16.png" CancelImageUrl="~/Images/icon_cancel_filter.png"    
InsertImageUrl="~/Images/icon_add_16.png">     
<HeaderStyle></HeaderStyle>    
</telerik:GridEditCommandColumn>   
    <telerik:GridButtonColumn CommandName="Delete" UniqueName="DeleteColumn" ButtonType="ImageButton" mageUrl="~/Images/icon_remove_16.png" />   
</Columns>   
<CommandItemSettings AddNewRecordText="Add new record" AddNewRecordImageUrl="~/Images/icon_add_16.png" />   
</MasterTableView> 

Any thoughts of what I can look for?

Thanks.
Steve

Pavlina
Telerik team
 answered on 23 Feb 2010
1 answer
120 views
Hello Telerik-Team,

in my RadGrid I need to link to an new page where i I can see and edit more information about the client.

But I don't want to transfer the Customer ID in the Querrystring!

Waht is th best way to do this?  GridHyperLinkColumn or GridButtonColumn ?

Are there example how to do this?

Thanks

Christian

 
Yavor
Telerik team
 answered on 23 Feb 2010
3 answers
514 views
Hello!

I have a very simple example below but am getting confusing results.  I was hoping that somebody could help me understand what is happening and how to get the desired results.

I have a RadAjaxManager configured so that an ASP.NET Button's click event updates a div (containing a label), with a corresponding RadAjaxLoadingPanel.

The button's server side click event looks like this:

protected void Button1_Click(object sender, EventArgs e) {  
 
     // Increment number in Label1  
     int i = Int32.Parse(Label1.Text);  
     Label1.Text = (i + 1).ToString();  
 
     // Sleep 5 seconds to simulate latency  
     Thread.Sleep(5000);  
 

Currently I have the RadAjaxManager's 'RequestQueueSize' property set to 0, the default.  I want to keep it this way so that if a 2nd request occurs before the 1st request's response returns, that 1st request will be cancelled and the 2nd request will be sent.

This is occuring, however, when you click the button twice within that five second wait, two undesrable things happen that I would not have expected to happen.

  1. The loading panel disappears on the 2nd click, even though the 2nd request is still processing.  I would like it to stay until the response from the 2nd click returns so that the user knows their 2nd request is still processing.  I have even tried forcing this behavior myself using the RadAjaxManager's 'OnRequestStart' and 'OnResponseEnd' client events (with the help of Telerik documentation) but was not able to get the loading panel to remain for both clicks within the 5 seconds.  Question: How can I get the loading panel to stay until the 2nd request's response returns?  Do I have something configured wrong? Note: I did notice that if I increase the RadAjaxManager's 'RequestQueueSize' that a loading panel remains until the last request's response returns, but unfortunately I need the RequestQueueSize set to 0.
  2. I notice that the order of events for the RadAjaxManager is slightly confusing.  I have some client-script that writes out to the screen every time the 'OnRequestStart' and 'OnResponseEnd' events get fired.  When I click the button twice within the five second wait, I see that these events get called in the following order:

 

    • OnRequestStart
    • OnRequestStart
    • OnResponseEnd
    • OnResponseEnd
    • OnResponseEnd

    Question: Why does the OnResponseEnd get called three times?  Note: if you continue to click the button more than twice, the 'OnResponseEnd' event gets called even more times.

Here is my aspx markup.  The javascript just writes which events were fired into a div at the bottom of the screen.  The two styles are included to better display what is happening.

<%@ 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"> 
 
<html xmlns="http://www.w3.org/1999/xhtml">  
<head id="Head1" runat="server">  
    <title></title>  
 
    <script type="text/javascript">  
 
        function WriteClientEvents(text) {  
 
            var div = $get("DivClientEvents");  
            div.outerHTML = text + "<br>" + div.outerHTML;  
 
        }  
 
        function AjaxRequestStart(sender, args) {  
 
            WriteClientEvents("Request");  
 
        }  
 
        function AjaxResponseEnd(sender, args) {  
 
            WriteClientEvents("Response");  
 
        }  
             
    </script> 
 
    <style type="text/css">  
         
        .loading  
        {  
            border: solid 1px black;  
            background-color: #fff;  
            height: 100px;  
            width: 200px;  
        }  
          
        #DivTimesClicked   
        {  
            border: solid 1px black;   
            height: 300px;  
            width: 300px;  
        }  
        
    </style> 
      
</head> 
<body> 
    <form id="form1" runat="server">  
   
        <Telerik:RadScriptManager ID="rsm1" runat="server">  
        </Telerik:RadScriptManager> 
          
        <Telerik:RadAjaxManager   
            ID="ram1"   
            runat="server"   
            RequestQueueSize="0"   
        > 
            <ClientEvents OnRequestStart="AjaxRequestStart" OnResponseEnd="AjaxResponseEnd">  
            </ClientEvents> 
            <AjaxSettings> 
                <Telerik:AjaxSetting AjaxControlID="Button1" EventName="Button1_Click">  
                    <UpdatedControls> 
                        <Telerik:AjaxUpdatedControl ControlID="DivTimesClicked" LoadingPanelID="LoadingPanel1" /> 
                    </UpdatedControls> 
                </Telerik:AjaxSetting> 
            </AjaxSettings> 
        </Telerik:RadAjaxManager> 
          
        <br /><br /> 
          
        <Telerik:RadAjaxLoadingPanel ID="LoadingPanel1" runat="server" Skin="" Transparency="30" BackgroundPosition="Center">  
            Loading...  
        </Telerik:RadAjaxLoadingPanel> 
          
        <asp:Button ID="Button1" runat="server" Text="Increment Times Clicked" OnClick="Button1_Click" /> 
          
        <br /><br /> 
          
        <div id="DivTimesClicked" runat="server">  
            Times Clicked:  
            <asp:Label ID="Label1" runat="server" Text="0"></asp:Label> 
        </div> 
          
        <br /><br /> 
          
        <h2>RadAjaxManager Client Events...</h2> 
        <hr /> 
        <div id="DivClientEvents">  
        </div> 
 
    </form> 
</body> 
</html> 

I look forward to understanding what is happening here.  Thank you for your help!
--Jason

Iana Tsolova
Telerik team
 answered on 23 Feb 2010
1 answer
70 views

hello,
we are using q3 2009 version with the hotfix.
the last item in the menu has sub items but somehow the user gets this error while mouseovering the item and waiting for the subitems to appear.
if i move the last item to another location in the menu,the error does not appear.

if the last item in the menu does not have sub items,the error does not appear.

regards

Peter
Telerik team
 answered on 23 Feb 2010
4 answers
766 views

Hi,
I use the following code to retrieve data from RadGrid's cells:

Dim i as integer = 1  
Dim CellValue as New String 
CellValue = RadGrid1.MasterTableView.Items(i).Item("ColumnUniqueName").Text 

It works well as long as the column type is GridBoundColumn.  But, when convert the column to GridTemplateColumn the above code returns blank value.
How can I retrieve data from a RadGrid when the RadGrid's column is a GridTemplateColumn?

Thanks,
Al

Princy
Top achievements
Rank 2
 answered on 23 Feb 2010
3 answers
80 views
Hi I am programatically binding a list to a radgrid. It works fine if I use GridBoundColumn controls ertc.. but when I want to add my own formatting I do it like this:
<telerik:RadGrid  ShowGroupPanel="true" AllowPaging="true" PageSize="10" AutoGenerateColumns="false" Width="700" ID="RadGrid1" runat="server"
 
<MasterTableView TableLayout="Fixed" > 
       
     <ItemTemplate> 
      
      
       <%# Eval("Subject" %> 
       <%# Eval("PostDate")%> 
       <%# Eval("Body")%> 
       <%# Eval("TotalViews")%> 
    
       
      
      
     </ItemTemplate> 
       
   
     
      </MasterTableView> 
 
 
</telerik:RadGrid> 
It tells me there are no records to display - I know there are records there as I can see them when I step into my code. Why does the above not display my records?
Thanks
Princy
Top achievements
Rank 2
 answered on 23 Feb 2010
1 answer
102 views
Hello,

Could you please take a look at it for this pic.
http://i47.tinypic.com/5by4b6.jpg
If i remove minimized , looks fine but start from minimized to refresh/pin ,, any addational adding looks like that one.
Please any idea.

regards,
Georgi Tunev
Telerik team
 answered on 23 Feb 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?