Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
159 views
I am using the ajaxRequest functionality to explicitly fire an ajax postback event from my javascript code.

I have a javascript function that generates the callback like this:
    <telerik:RadCodeBlock ID="codeBlock" runat="server"> 
        <script type="text/javascript"> 
        //<![CDATA[
        function callPostbackFunction(args)
        {
            var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>");
            ajaxManager.ajaxRequest(args);
        }
        //]]> 
        </script> 
    </telerik:RadCodeBlock> 
and, a function in the server side code, like this:
    protected void RadAjaxManager1_AjaxRequest(object sender, AjaxRequestEventArgs e) 
    { 
        String[] list; 
        list = e.Argument.Split(','); 
        String tmp; 
        for (int i = 0; i < list.Length; i++) { 
            tmp = list[i]; 
        }    
    } 

I have verified that, when the ajaxManager.ajaxRequest(args); line is executed in my client-side javascript, the value of "args" is correct (it is a comma seperated list of values).

But, when I try to access the argument in the server side code, the value in e.Argument is just a string that says "[Object object]".

I can't figure out what is causing this. Has anyone seen this behavior before? What have I done wrong? The examples I have seen, and that I am following make it look pretty simple but, I have somehow managed to make it weird.

Thanks for any help you can provide.


Roger
Top achievements
Rank 1
 answered on 11 May 2010
1 answer
101 views
Is it possible to add items to the rotator clientside?  I want to populate it via a webservice callback...
Fiko
Telerik team
 answered on 11 May 2010
1 answer
140 views
Hello,

I'm using latest internal build: 2010.1.504.20.
I'm experiencing strange problem when using TextBox and RadInputManager in in IE6. The TextBox width becomes bigger when I click submit button several times. And return back to original size when I hover it.
In short, I have outer div that specifies width, inner div that specifies padding. TextBox, RadInputManager and submit button are inside inner div. Pretty simple, XHTML and CSS are fine there.

<html xmlns="http://www.w3.org/1999/xhtml"> 
<head runat="server"> 
    <title></title> 
    <style> 
        .btb {float:left;width:245px;} 
        .btb .inner {color:#FFFFFF;padding:40px 10px 20px;} 
        .contact-txt input, 
        .contact-txt textarea 
        {margin-bottom: 10px; color: #666666 !important;} 
        .contact-txt .contact-msg-txt textarea 
        {height: 90px; margin-bottom: 5px;} 
        .contact-txt .RadInputMgr_Default 
        {border-color: #277596 !important; width: 100%;} 
        .contact-btn 
        {float: right; text-decoration: none; color: #33CCFF;} 
        .contact-btn:hover 
        {text-decoration: underline;} 
    </style> 
</head> 
<body> 
    <form id="form1" runat="server"> 
    <asp:ScriptManager ID="ScriptManager1" runat="server"> 
    </asp:ScriptManager> 
     
    <div class="btb"><div class="inner"> 
        <div class="contact-txt"> 
        <div class="contact-msg-txt"> 
            <asp:TextBox runat="server" ID="MessageText" TextMode="MultiLine" ValidationGroup="Contact" /> 
        </div> 
        </div> 
        <asp:LinkButton ID="LinkButton1" ValidationGroup="Contact" runat="server" Text="Send" CssClass="contact-btn" /> 
    </div></div> 
    <telerik:RadInputManager  ID="ContactRadInputManager" runat="server"> 
        <telerik:TextBoxSetting BehaviorID="MessageBehavior" EmptyMessage="Message" ErrorMessage="Please enter message" 
                                Validation-IsRequired="true" Validation-ValidationGroup="Contact"> 
            <TargetControls> 
                <telerik:TargetInput ControlID="MessageText" /> 
            </TargetControls> 
        </telerik:TextBoxSetting>     
    </telerik:RadInputManager> 
    </form> 
</body> 
</html> 

Just try to run following code with latest internal build in IE6 (unfortunately there is no way to attach test project to this thread).

Thank you,
Denis.
Dimo
Telerik team
 answered on 11 May 2010
1 answer
88 views
I'm trying to add a user control inside a dynamically created dock. My add method looks as follows:

private RadDock CreateRadDock(string title, string contentURL, string forbiddenZone)
    {
        RadDock dock = new RadDock();
        dock.DockMode = DockMode.Docked;
        dock.UniqueName = Guid.NewGuid().ToString().Replace("-", "a");
        dock.ID = string.Format("RadDock{0}", dock.UniqueName);
        dock.Title = title;
        dock.Width = Unit.Percentage(100);
        dock.ForbiddenZones = forbiddenZone.Split(',');

        //dock.Commands.Add(new DockCloseCommand());
        dock.Commands.Add(new DockExpandCollapseCommand());

        Panel pnlDockContent = new Panel();
        pnlDockContent.ID = "Content" + dock.UniqueName;
        pnlDockContent.Controls.Add(LoadControl(contentURL));
        //dock.ContentContainer.Controls.Add(pnlDockContent);
        
        StringBuilder sb = new StringBuilder();
        StringWriter tw = new StringWriter(sb);
        HtmlTextWriter hw = new HtmlTextWriter(tw);

        pnlDockContent.RenderControl(hw);
        dock.Text = sb.ToString();
        
        return dock;
    }

This works fine if the user control i'm loading doesn't have any Asp.Net controls. But whenever there's an Asp.Net control inside, the pnlDockContent.RenderControl call fails & that's obvious. The issue for which i had to chose this way is if the dock content is added as a control, the content doesn't persist on drag & drop of the dock. Can someone please help me with this?
Pero
Telerik team
 answered on 11 May 2010
3 answers
194 views
Hello,

I try to stick to block the images, when i use the paste.

when you make a copy and paste an article I would keep the text and formatting any external links, but not paste images.
how do I do?


Ch.



Schlurk
Top achievements
Rank 2
 answered on 11 May 2010
1 answer
236 views
I have created a ticket for this as well, but I thought I would submit here as well and see if anyone has seen this behavior.

I am having an issue with the RadGrid and partial postbacks.  For the partial postbacks I am using the RadScriptManager, RadAjaxManager, and the RadAjaxLoadingPanel.  

The scenario is pretty basic.  I click a button, some data is retrieved, and bound to the grid.  The issue that is happening is the data retrieval process is pretty lengthy (upwards of 15-30 seconds).  When the partial postback returns the grid has all of the data, but the styling for filtering, sorting, etc is all messed up.  

A couple troubleshooting steps I have taken is to hard code the data being returned so it is faster.  That actually fixes the problem and the grid comes back styled perfectly, so I am thinking it has to be the time to return is causing issues.  I did find another person on the forum who described possibly a similar problem, and the recommendation was to increase the ScriptManager.AsyncPostBackTimeout value, which I have done, and that did not help.

Any assistance would be greatly appreciated.  I am under the gun to get this done asap!  Thanks
Dimo
Telerik team
 answered on 11 May 2010
3 answers
178 views
Dear Telerik Team,

I build my project in 2009.3.1208.20 version with custom skin everything working good. Now I upgraded the version to 2010.1.415.35 then Button and Datepicker control css are not working properly. I am getting disturbed css for button and date pickers in a form. I hope you will understand the problem.


Thanks and Regards
---------------------------
Pradeep
Dimo
Telerik team
 answered on 11 May 2010
5 answers
206 views
  <radspl:RadSplitter ID="spltSrchRes" runat="server" Skin="Outlook" Width="100%"   
        Visible="true" ResizeWithParentPane="true" ResizeWithBrowserWindow="true" ResizeMode="EndPane" Height="700">  
         <radspl:RadPane ID="pnRefSrch" runat="server" Width="100%" Scrolling="None" >    
 
   <Telerik:RadGrid Width ="100%"  ID="dgResults" EnableAJAX="True" HorizontalAlign="Center" runat="server" AllowPaging="True" AllowSorting="True" 
                    Font-Names="Tahoma" OnItemCommand="dgResults_OnItemCommand" OnPageIndexChanged="dgResults_OnPageIndexChanged" Font-Size="X-Small" GridLines="None" Skin="Office2007" 
                    OnSortCommand="dgResults_SortCommand" OnPreRender="dgResults_PreRender" OnExcelExportCellFormatting="dgResults_ExcelExportCellFormatting">  
                    <AlternatingItemStyle  Font-Size="8pt" CssClass="MyAlternatingClass" /> 
                    <ItemStyle Font-Names="Tahoma" Font-Size="8pt" CssClass="MyClass" wrap="False" /> 
                    <HeaderStyle Font-Bold="True" Font-Size="9pt" ForeColor="Black" Wrap="False" HorizontalAlign="Center"/>  
                    <ClientSettings AllowColumnsReorder="false" ReorderColumnsOnClient="false" AllowAutoScrollOnDragDrop="false"   > 
                    <Resizing AllowColumnResize="True" ClipCellContentOnResize="False" ></Resizing>  
                    <Scrolling AllowScroll="True" UseStaticHeaders ="true"  ScrollHeight="550px" /> 
                     <Selecting AllowRowSelect="True" /> 
                        <ClientEvents OnGridCreated="GridCreated"  /> 
                    </ClientSettings>                      
                    <MasterTableView Width ="99%" >   
                    <Columns>   
 
......  
 
   
 
 
 
Hi Telerik experts:

I use static headers in my grid. As I need to show many columns, I expect there is a horizontal scroll bar to scroll the grid when the number of columns increases.

1) However, with static headers=true, there is no horizontal scroll bar. I had the scroll bar when I didn't use static hearders (which default is false.)

2) Also, another problem is: with static headers, the column shows with equal width. But I need it to be shown with content width (auto instead of fixed.)

For your reference, I put some part of my code above.

Thanks.





Pavlina
Telerik team
 answered on 11 May 2010
3 answers
213 views
I have asp:textbox that is not visible when the page loads. With a click event I make it visible. I am using RadAjaxManager. The textboxes that have watermark extenders, when they become visible the corners are not rounded, but the textboxes without watermark extenders do have rounded corners. Can someone please help.
Georgi Tunev
Telerik team
 answered on 11 May 2010
2 answers
185 views
It only removes the selected item from the radgrid but it's still persisting into database.
How do i delete selected record using GridClientDeleteColumn? Thanks
El
Top achievements
Rank 1
 answered on 11 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?