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

We are getting javascript error while working with asp.net dropdown inside the telerik . OnselectIndex change of dropdown getting javascript error "Sys.WebForms.PageRequestManagerParserErrorException".
 

Please verify the below sample code and provide the resolution.

Thanks InAdvance.

aspx code :

<

 

 

form id="form1" runat="server">

 

 

 

<telerik:RadScriptManager ID="ScriptManager" runat="server" />

 

 

 

<telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server">

 

 

 

<telerik:RadPanelBar runat="server" ID="RadPanelBar1" ExpandMode="SingleExpandedItem" Width="740px">

 

 

 

<Items>

 

 

 

<telerik:RadPanelItem Expanded="True" Text="Step 1: Account Information" runat="server" Selected="true">

 

 

 

<Items>

 

 

 

<telerik:RadPanelItem Value="AccountInformation" runat="server">

 

 

 

<ItemTemplate>

 

 

 

 

<asp:DropDownList ID="ddTest" runat="server" AutoPostBack="true" OnSelectedIndexChanged="ddTest_OnSelectedIndexChanged">

 

 

 

<asp:ListItem>First</asp:ListItem>

 

 

 

<asp:ListItem>Second</asp:ListItem>

 

 

 

<asp:ListItem>Third</asp:ListItem>

 

 

 

 

</asp:DropDownList>

 

 

 

</ItemTemplate>

 

 

 

</telerik:RadPanelItem>

 

 

 

</Items>

 

 

 

</telerik:RadPanelItem>

 

 

 

</Items>

 

 

 

 

</telerik:RadPanelBar>

 

 

 

</telerik:RadAjaxPanel>

 

 

 

 

</form>

 


C# Code :

protected void ddTest_OnSelectedIndexChanged(object sender , Eventargs e)
{
   Response.write("test");
}

Even after removing response.write in the  code part. getting same javascript issue.
Princy
Top achievements
Rank 2
 answered on 12 Aug 2011
1 answer
98 views
I have a grid that, upon new or edited record displays GridNumericColumns with partially prepopulated values (e.g. 1234).

When clicking the cell, the prepopulated value is highlighted. Any typing will clear the prepopulated value. I don't want that.

Ideally, I'd like the cursor to position after the partially prepopulated value when the user clicks the cell, so they can complete the value (e.g. 12345678).

Any ideas?

Richard
Tsvetina
Telerik team
 answered on 12 Aug 2011
2 answers
359 views
Hi there,
        I have a main grid and a parent grid inside the main grid in a nesteview Template. Is there any way to refer the parent GridDataItem in the child grid'd itemDataBound event ? Please find the code below for your reference. Any help would be appreciated
<telerik:RadGridSkin="Office2007"runat="server"ID="rdGd1"ShowFooter="False"
                                AllowSorting="True"AllowPaging="True"   PageSize="10"
                                GridLines="None"
                                <MasterTableViewDataKeyNames="assetNodeID"AutoGenerateColumns="False"Name="MainGrid"
                                    CommandItemDisplay="Top"HierarchyLoadMode="ServerOnDemand"
                                    <CommandItemTemplate
                                        <asp:LabelID="lblHeaderr"runat="server"></asp:Label
                                    </CommandItemTemplate
                                      <Columns
.... 
.... 
..... 
  </Columns
                                    <NestedViewTemplate
    
         <asp:Panel runat="server"ID="InnerContainer"
<telerik:RadGrid id="childGrid" runat="server"  OnItemDataBound="childGrid_ItemDataBound">
 <MasterTableView>
<columns>
.....
....
....
</columns>
 </MasterTableView>
  
  
</telerik:RadGrid ></asp:Panel
                                    </NestedViewTemplate
 <ExpandCollapseColumnVisible="True"
                                    </ExpandCollapseColumn
                                </MasterTableView
                            </telerik:RadGrid>
ProtectedSuchildGrid_ItemDataBound(ByValsource AsObject, ByVale AsTelerik.Web.UI.GridCommandEventArgs)    
            ....   Here Here I need the dataItem details of the parent grid
  EndSub
Muhamed Shafi
Top achievements
Rank 1
 answered on 12 Aug 2011
3 answers
266 views
Is there a way to center the RadGrid Edit Popup Window in the browser window? I have found a way to center it in the RadGrid, but I would prefer it to be in the center of the whole web page. 

Thanks.
Shinu
Top achievements
Rank 2
 answered on 12 Aug 2011
1 answer
77 views
Hi,

I have a rad grid with some records.

When I collapse a record for edit and click on submit button a java script function is called. I need to get the all field values of this row in java script. Please help me on how can I get all values of current record in java script.

Thanks.
Shinu
Top achievements
Rank 2
 answered on 12 Aug 2011
1 answer
112 views

I set the AlwaysVisible property on the MasterTableView, but I also set the Position to be Top and Bottom. When the PageSize is greater than the record count and there is only 1 page of data (PageSize is 10, but 4 records are returned) the pager only displays at the bottom. I would like the Pager to either display top and bottom OR allow for the section where the pager resides to be available to the user to display page count and record count (4 records).

How can I provide this? It seems like "something is missing" when the pager doesnt display in with records less than the page size.

Thanks,
Shinu
Top achievements
Rank 2
 answered on 12 Aug 2011
1 answer
363 views

Hello.

In order to familiarize with the RadGrid component, I have created a small application whose grid is populated by a web service.

Default.aspx

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="WebApplication1._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">
  
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
        </telerik:RadScriptManager>
  
        <telerik:RadGrid ID="RadGrid1" runat="server">
            <MasterTableView>
                <Columns>
                    <telerik:GridBoundColumn DataField="ID" HeaderText="ID" DataType="System.Int32" />
                    <telerik:GridBoundColumn DataField="Name" HeaderText="Name" DataType="System.String" />
                </Columns>
            </MasterTableView>
            <ClientSettings>
                <DataBinding Location="WebService.cs" SelectMethod="RetrieveRows" />
            </ClientSettings>
        </telerik:RadGrid>
    </form>   
</body>
</html>

WebService.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ServiceModel;
using Telerik.Web.UI;
  
namespace WebApplication1
{
    [ServiceContract(Namespace = "")]
    [System.Web.Script.Services.ScriptService]
    public class WebService
    {
        public WebService () 
        {
        }
   
        [OperationContract]
        public Dictionary<string, object> RetrieveRows(int startRowIndex, int maximumRows, List<GridSortExpression> sortExpression, List<GridFilterExpression> filterExpression)
        {
            Dictionary<string, object> dictionary = new Dictionary<string, object>();
            dictionary.Add("Data", new[] { new { ID = 1234, Name = "Test" }});
            dictionary.Add("Count", 1);
            return dictionary;
        }
    }
}

The compilation was successful, but the following error message was displayed at runtime by the built-in script debugger of Internet Explorer:
Line: 6563
Error: Sys.ArgumentException: Cannot deserialize empty string.
Parameter name: data

I would appreciate whether some assistance could be provided to solve this problem.

Last but not least:
a) I was wondering how the application could be implemented using a server-side binding solution.
b) What is Telerik's recommendation in regard to client versus server-side binding implementations using a web service?

Thank you in advance.
Paulo

Shinu
Top achievements
Rank 2
 answered on 12 Aug 2011
5 answers
156 views
hi,
plz give me a sample for manually insert update delete in rad-grid with using session for row by row user entry.
save data on final submit button.
i am creating row dynamically on click of newrow button user make entry then again for new row untill last entry.
so plz give me any sample code related to such example where user first make all entry and store in session variable
and at last on submit button save all value in database here i am using 3 tables.
thanks
Shinu
Top achievements
Rank 2
 answered on 12 Aug 2011
2 answers
81 views
Hi,

I have a RadTreeView inside a RadComboBox which in turn is inside a UpdatePanel.
Data is loaded in a heirarchical manner.

It works fine. But I get a "stack overflow at line:2086" error randomly from
the WebResource.xsd file.

I am not sure what is the cause of this error.
Does anyone has any inputs on this.

Thanks
Steven
Top achievements
Rank 1
 answered on 11 Aug 2011
1 answer
118 views
I have been searching all over for an answer to this but to no avail... I am hoping someone here can help me.
I have a form that is intended to send field information to a support email address. I have disabled validation on all of the controls on this form to troubleshoot this.
When i fill the form out and click submit, it works fine, i get my Email as expected...

However, if i have special characters in any of the radtextbox fields, i get a validation error. Just the simple phrase <ValidateThis> will break the page.

Now i have created a routine to clean the text and replace the characters which ascii equivalents but the problem is that the validation error occurs before anything is run. How do i intercept this?

Thanks
Phil
Pavlina
Telerik team
 answered on 11 Aug 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?