Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
144 views
I have the following JavaScript code that creates a really simple JSON object...

var data = {'MyID':1,'MyItem':'This is the first item'};
var JSONdata = JSON.stringify(data);
$find('<%= RadAjaxManager1.ClientID %>').ajaxRequest(JSONdata);

This generates the following JSON string after running the object through the stringify method...

{"MyID":1,"MyItem":"This is the first item"}

This is valid JSON according to JSONLint.com.

Calling the .ajaxRequest() method results in Sys.WebForms.PageRequestManagerServerErrorException - "Specified cast is not valid"

It's not even getting to my RadAjaxManager1_AjaxRequest() event handler where I have a breakpoint set to inspect the value of e.argument.

What's wrong here?

I'm using version 2010.3.1317.35 of the Telerik controls.

Rob  
Pavlina
Telerik team
 answered on 25 Dec 2012
5 answers
166 views
I have an usercontrol that has a RadTabStrip control. This usercontrol is loaded in SharePoint 2007. The problem is that the Tabclick event is working for IE, Chrome, and Firefox but not for Safari.

I have a Breakpoint in the RadTabStrip1_TabClick event and I found out that code never is running.

I need your help!!
Safari 5.1.7
SharePotin 2007
Telerik 3.5


************Usercontrol*********

<%@ Register Assembly="Telerik.Web.UI, Version=2010.3.1109.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4"
    Namespace="Telerik.Web.UI" TagPrefix="telerik" %>


<%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" 
   Assembly="Microsoft.SharePoint, Version=11.0.0.0, Culture=neutral, 
   PublicKeyToken=71e9bce111e9429c" %>
<SharePoint:CssRegistration name="Ajax.Settings.css" runat="server"/>      
  
<asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
         <telerik:RadTabStrip runat="server" ID="RadTabStrip1" OnTabClick="RadTabStrip1_TabClick" AutoPostBack="True" CausesValidation="false">
            <Tabs>
                <telerik:RadTab runat="server" Text="Root RadTab1">
                    <Tabs>
                        <telerik:RadTab runat="server" Text="Child RadTab 1">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Child RadTab 2">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Child RadTab 3">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Child RadTab 4">
                        </telerik:RadTab>
                    </Tabs>
                </telerik:RadTab>
                <telerik:RadTab runat="server" Text="Root RadTab2">
                    <Tabs>
                        <telerik:RadTab runat="server" Text="Child RadTab 1">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Child RadTab 2">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Child RadTab 3">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Child RadTab 4">
                        </telerik:RadTab>
                    </Tabs>
                </telerik:RadTab>
                <telerik:RadTab runat="server" Text="Root RadTab3">
                    <Tabs>
                        <telerik:RadTab runat="server" Text="Child RadTab 1">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Child RadTab 2">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Child RadTab 3">
                        </telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Child RadTab 4">
                        </telerik:RadTab>
                    </Tabs>
                </telerik:RadTab>
            </Tabs>
        </telerik:RadTabStrip>

*******C# Code*******

  protected void Page_Load(object sender, System.EventArgs e)
        {
     
        }
        protected void RadTabStrip1_TabClick(object sender, RadTabStripEventArgs e)
        {
            Label1.Text="TabClick: " + e.Tab.Text;
        }
        protected void Page_PreRender(object sender, EventArgs e)
        {
            EnsureUpdatePanelFixups();
        }
        private void EnsureUpdatePanelFixups()
        {
            RadScriptManager.RegisterStartupScript(this, GetType(), "UpdatePanelFixup", "_spOriginalFormAction = document.forms[0].action; _spSuppressFormOnSubmitWrapper=true;", true);
        }     



Kalina
Telerik team
 answered on 25 Dec 2012
1 answer
154 views

Hello,

I am new at Telerik RadGrid in Ajax/ASP .NET.

I am trying to allow the user of my application to be able to re order the columns of my RadGrid. I found on your website that :

GridDragDropColumn  has to be inserted in the Columns collection of a GridTableView, But as my RadGrid columns are autogenerated, I have no <Column> tag in the description of my RadGrid. So I am trying to understand where should the GridDragDropColumn  tag be inserted to allow Columns drag and drop (and re-ordering).
I tried to insert it in the <Columns> description of my MasterTableView (see the code below) but when running it, I cannot drag any of my columns ?

Another point is that I want that my columns can also be sorted by one click on the header of the column. Is that compatible with the GridDragDropColumn  option ?

Thank your for your help.

Here is the code of my grid in my ASPX file :

<telerik:RadGrid ID="GridView1" runat="server"
        ActiveItemStyle-BorderStyle="Solid" AllowSorting="True"
        AllowMultiRowSelection="True" AllowFilteringByColumn="True"  
        TableLayout="Fixed" ValidationSettings-EnableValidation="False"
        ScrollHeight="200px"  Height="700px"  Width = "98%" table-layout="auto">
    <MasterTableView  TableLayout="auto">
   <Columns>
    <telerik:GridDragDropColumn HeaderStyle-Width="18px" />
                        
      </Columns>
 
       <NestedViewTemplate>
           <asp:Panel runat="server" ID="configControlContainer" CssClass="viewWrap" Visible="true" BackColor="PaleGoldenrod">
            <table>
           <tr>
           <td><telerik:RadTextBox ID="RadTextbox1" runat="server">
           </telerik:RadTextBox>
            </td>
             </tr>
             <tr>
           <td><telerik:RadButton ID="RadButton1" Text="Confirm" runat="server"
                                                      OnClick="btn_Click">
            </telerik:RadButton>
 
            
             </td>
              </tr>
              </table>
            </asp:Panel>
            </NestedViewTemplate>
 
              <DetailTables>
                        
             </DetailTables>
          </MasterTableView>
           <ClientSettings  AllowRowsDragDrop="true">
              <Selecting AllowRowSelect="True" EnableDragToSelectRows="false" />
              <Scrolling AllowScroll="True" ScrollHeight="475px" UseStaticHeaders="true" FrozenColumnsCount="1" SaveScrollPosition="True" />
            </ClientSettings>
              
          </telerik:RadGrid>

Eyup
Telerik team
 answered on 25 Dec 2012
2 answers
283 views
am using telerik tab strip control in page2.aspx...am calling this page frompage1.aspx.... from there itself i want to mention the tab which i want to see first.in page1.aspx i have equal no of menu for each tab. for ex, if i click on 3rd menu then it shd redirect to page2.aspx and it shd focus on 3rd tab....



Kalina
Telerik team
 answered on 25 Dec 2012
2 answers
68 views

Hi,

How can I change the background image of RibbonBar?

Thanks in advance

Ivan Zhekov
Telerik team
 answered on 25 Dec 2012
1 answer
160 views
Hello,

I'm encountering an exception using RadGrid's NestedViewTemplate feature.
If I set HierarchyDefaultExpanded="true" RadGrid, NestedViewTemplate is rendering correctly but all rows are expanded which is not very interesting. So i leave HierarchyDefaultExpanded to false so rows are initially collapsed when i expand a row following exception is raised

[System.InvalidOperationException: Collection was modified; enumeration operation may not execute.]
System.Web.UI.ControlCollectionEnumerator.MoveNext() +8672514
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +639
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +630
   Telerik.Web.UI.RadFormDecorator.DecorateAspNetControls() +68
   Telerik.Web.UI.RadFormDecorator.ControlPreRender() +834
   Telerik.Web.UI.RadWebControl.OnPreRender(EventArgs e) +47
   System.Web.UI.Control.PreRenderRecursiveInternal() +80
   System.Web.UI.Control.PreRenderRecursiveInternal() +171
   System.Web.UI.Control.PreRenderRecursiveInternal() +171
   System.Web.UI.Control.PreRenderRecursiveInternal() +171
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +842
 
I have tested a lot of scenarios with no success. RadGrids are both initialized programmatically (ItemCommand, ItemCreated, PreRender, NeedDataSource for NHibernate list).

After testing, exception raise when system tries to render manual columns (GridDateTimeColumn, GridBoundColumn) as  AutoGenerateColumns="False". If i remove manual columns, expand/collapse is working.
Eyup
Telerik team
 answered on 25 Dec 2012
1 answer
644 views
Hi, we're using the FormDecorator and I notice on the front end the dropdownlist renders as a div with spans instead of a traditional html select list.

When I try to use jquery to set the selected value after the control renders it doesn't change. I'm guessing because this is technically not a select list anymore.

Is there any work around to this?
Marin Bratanov
Telerik team
 answered on 25 Dec 2012
8 answers
557 views
I was wondering how to go about hiding several column's in a child of a Hierarchical RadGrid if there is no data found for those columns. It would be quite nice to be able to do the same on the parent as well.

I've had a good search on the forums but can't find a good example to follow..

can anyone suggest a way to do this..

many thanks
Eyup
Telerik team
 answered on 25 Dec 2012
1 answer
69 views
Hi Telerik Team,

I created a RadEditor ( radEditor ) in my webpage. I set :

radEditor.TableLayoutCssFile = myCustimizedTableCssFile;
radEditor.CssFiles.Add ( myCustimizedCssFile );

In the editor iframe, it will automatic load myCustimizedTableCssFile first then load myCustimizedCssFile. Is there have way to switch them?

Thanks,
 
Rumen
Telerik team
 answered on 25 Dec 2012
3 answers
176 views
Deat Telerik-Team

I would be nice to have a property to show or hide the content and title icon.

Regards,
Christian
Marin Bratanov
Telerik team
 answered on 25 Dec 2012
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
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
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?