Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
308 views
Hi everyone,

Please help me to enable ajax for telerik:RadGrid (assembly="Telerik.Web.UI")

I'm using EnableAjaxSkinRendering="True" but ajax does not work.

Thanks in advance

  <telerik:RadGrid ID="_radGridListInfulfillmentOrder" runat="server" Skin="" AutoGenerateColumns="false"
            AllowSorting="true" OnNeedDataSource="RadGridListInfulfillmentOrderNeedDataSource"
            OnItemCommand="RadGridListInfulfillmentOrderItemCommand" EnableAjaxSkinRendering="True">
            <MasterTableView DataKeyNames="OrderID" EditMode="PopUp" ShowHeader="true" GridLines="None"
                CommandItemDisplay="None" NoMasterRecordsText="No data" CommandItemSettings-AddNewRecordText="List In-fulfillment Order"
                AllowNaturalSort="false">
                <Columns>
                    <telerik:GridTemplateColumn UniqueName="MyCustomTemplateColumn" ShowSortIcon="false">
                        <HeaderTemplate>
                            <table id='neworderlist' cellspacing='0'>
                                <tr>
           
  <telerik:RadGrid ID="_radGridListInfulfillmentOrder" runat="server" Skin="" AutoGenerateColumns="false"
            AllowSorting="true" OnNeedDataSource="RadGridListInfulfillmentOrderNeedDataSource"
            OnItemCommand="RadGridListInfulfillmentOrderItemCommand" EnableAjaxSkinRendering="True">
            <MasterTableView DataKeyNames="OrderID" EditMode="PopUp" ShowHeader="true" GridLines="None"
                CommandItemDisplay="None" NoMasterRecordsText="No data" CommandItemSettings-AddNewRecordText="List In-fulfillment Order"
                AllowNaturalSort="false">
                <Columns>
                    <telerik:GridTemplateColumn UniqueName="MyCustomTemplateColumn" ShowSortIcon="false">
                        <HeaderTemplate>
                            <table id='neworderlist' cellspacing='0'>
                                <tr>
           
  <telerik:RadGrid ID="_radGridListInfulfillmentOrder" runat="server" Skin="" AutoGenerateColumns="false"
            AllowSorting="true" OnNeedDataSource="RadGridListInfulfillmentOrderNeedDataSource"
            OnItemCommand="RadGridListInfulfillmentOrderItemCommand" EnableAjaxSkinRendering="True">
            <MasterTableView DataKeyNames="OrderID" EditMode="PopUp" ShowHeader="true" GridLines="None"
                CommandItemDisplay="None" NoMasterRecordsText="No data" CommandItemSettings-AddNewRecordText="List In-fulfillment Order"
                AllowNaturalSort="false">
                <Columns>
                    <telerik:GridTemplateColumn UniqueName="MyCustomTemplateColumn" ShowSortIcon="false">
                        <HeaderTemplate>
                            <table id='neworderlist' cellspacing='0'>
                                <tr>
           
  <telerik:RadGrid ID="_radGridListInfulfillmentOrder" runat="server" Skin="" AutoGenerateColumns="false"
            AllowSorting="true" OnNeedDataSource="RadGridListInfulfillmentOrderNeedDataSource"
            OnItemCommand="RadGridListInfulfillmentOrderItemCommand" EnableAjaxSkinRendering="True">
            <MasterTableView DataKeyNames="OrderID" EditMode="PopUp" ShowHeader="true" GridLines="None"
                CommandItemDisplay="None" NoMasterRecordsText="No data" CommandItemSettings-AddNewRecordText="List In-fulfillment Order"
                AllowNaturalSort="false">
                <Columns>
                    <telerik:GridTemplateColumn UniqueName="MyCustomTemplateColumn" ShowSortIcon="false">
                        <HeaderTemplate>
                            <table id='neworderlist' cellspacing='0'>
                            
Maria Ilieva
Telerik team
 answered on 09 Dec 2010
1 answer
69 views
I have started getting occasional errors logged from our web server.

It looks like a specific user, and possibly only some of the time.  If it happens AJAX won't work on our site (I imagine), which would make using it quite difficult .  There are maybe 200 users, who are usually on all day, but no-one has complained (yet).

This is error, logged from our default error page.  The end of the axd decoration has obviously got corrupted with some javascript.
Why does the same corrupt filename get referenced time and again ?  Has the browser cached it ?

The page you requested cannot be found.

Request RawUrl = /SeaPlanner/ScriptResource.axd?d=MZN8mrjHFHeJS_HFuw_hoFXoRri86JQ_-n6xsd10tRLAuzBPjqE1NaoSazV5LzG-X6cWyuwm-ikDSRGesWeS0t8fMPuiMKYEafpSBgnMVfaRuzktBack('ctl00$mnuMain','Log%20Off')

Referrer http://.../Seaplanner/default.aspx

UserHostAddress 81.132.73.121

UserHostName 81.132.73.121

12/2/2010 11:54:54 AM,

System.Web.Extensions,

This is an invalid script resource request.,

 

   at System.Web.Handlers.ScriptResourceHandler.ProcessRequest(HttpContext context)

   at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()

   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

HTTP_USER_AGENT:Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 2.0.50727; .NET CLR 1.1.4322; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)

The uncorrupted axd file starts thusly:
// Name:        MicrosoftAjaxWebForms.debug.js
// Assembly:    System.Web.Extensions
// Version:     3.5.0.0
// FileVersion: 3.5.30729.3644
//-----------------------------------------------------------------------
// Copyright (C) Microsoft Corporation. All rights reserved.
//-----------------------------------------------------------------------
// MicrosoftAjaxWebForms.js
// Microsoft AJAX ASP.NET WebForms Framework.

Any ideas ????
Iana Tsolova
Telerik team
 answered on 09 Dec 2010
0 answers
86 views
I have a page that has a RadMenu and a RadGrid used together. The RadGrid is used in client-side mode. This means that the loading, saving, editing and creation of new records is done via ajax. The grid seems to work fine but after sometime it appears that The menu dropdowns tend to be slower and after more use the entire page freezes. I am not sure whether it is this combo that causes this effect or either of the controls since a lot of js is being used to automate the menu dropdown and the ajax calls to the. This is the order in which the error is reprodcuded.
 
The menu control is located up above in a separate iframe and the grid is below in a separate iframe. This makes the scenario more peculiar since different js files are loaded in two iframes and there is no interaction between the two.
 
What could be the cause of the sudden freezing, a memory leak perhaps? Better still could it be a general problem when a lot of ajax interactions occur and other events are fired before the callbacks return?
 
On the video once can see that when the grid page loads everything seems fine, but after firing some events and performing some actions, the menu starts taking a lot of time to load. It reaches a point that it takes such a long time for the drop downs to display and eventually the entire browser tab freezes.

I have uploaded a video of the effects and here is the link:
http://megaswf.com/simple_serve/87153/
Waliaula
Top achievements
Rank 1
 asked on 09 Dec 2010
1 answer
99 views
Hi,

I'm using a tooltip along with RadToolTipManager.  On some instances, the saving of a tooltip is unsuccessful and I'm not completely sure why. 

I've a got a button that does a postback which is caught in the OnAjaxUpdate event.

There is no error generated when the save is unsuccessful.

How does RadToolTipManager handle errors?  Is there a way to catch those ajax errors that might occur?

Thanks,

Coy
Svetlina Anati
Telerik team
 answered on 09 Dec 2010
1 answer
240 views
Using the Web2.0 skin and the Rad ListBox and GridView, I'm not seeing images - check boxes, update "finger", arrows, etc.  No custom icons are showing in any control.  However, styles are applied, colors, clean gradients, etc so the control is seeing the Web2.0 styling, but I'm feeling like I'm missing a step here.

I was under the undertanding that the embedded DLL would contain all the image files and CSS and there is/was no need to copy sprite files, CSS, or images manually.  However, I see a ton of posts about doing just that - presumably on earlier iterations.

Please advise.  Do I need to copy images?  If so, from where to where?  I opened up the Telerik folder and every control has it's own couple images - seems like a lot of cut/paste work it's not like there's one folder with Web2.0 images.

Sorry for the beginner question.   I haven't found a really clear setup workflow tutorial for VS2010.  Other documentation is great - just seems like there's a couple ways to accomplish things, which is confusing.

Pavlina
Telerik team
 answered on 09 Dec 2010
3 answers
174 views
I have a template column with combo box in a grid. When user selects value from a combo box I want to update other 2 cols in a same row. How do I do this?

Thanks
Martin
Telerik team
 answered on 09 Dec 2010
1 answer
111 views
Hi
I am facing problem in multiple file selection in RadAsyncUpload on IE8 .It is working properly on IE7 and  selecting multiple files but not able to select multiple files on IE8.
So please let me know what to do to make it work properly on IE8.
Thanks
Genady Sergeev
Telerik team
 answered on 09 Dec 2010
1 answer
142 views
Hi! I;m wondering what basic changes I'll have to make in order for the Upload / Using RadUpload in an Ajaxified Grid Demo to work exactly as it is but in a child form where a RadAjaxProxy resides and the Master page has the AjaxManager. Also, I'm not dealing with images. I'm dealing with documents: Word, Text, Excel, etc. I only need to store the document path along with the usual stuff (employee ID, description, DocName, etc). I'll upload the actuall document to a server folder and not into the DB.

Kindly suggest as the example uses scripts and RadAjaxPanel. Eagerly waiting. Thank you.
Genady Sergeev
Telerik team
 answered on 09 Dec 2010
1 answer
167 views
Hi,

I have an ajaxified RadTreeView control. The treeview lists a database key field. Each node click populates the right hand side form based on the tree node value. I have used a AjaxLoadingPanel to give a rich user experience saying that the forms are getting loaded. Now I have a typically scenario when some form values gets changed and if the user clicks on another rad tree node I want to alert the user saying that "Data Has Been Changed. Do you want to save?". I have gone through the radconfirm forums and I managed to show the confirm box. Now I made some changes to the form and now I click on another node what is happening is the code i wrote on node click is executing and the form gets loaded based on the new rad tree node value and at last the radconfrim window opens up. I want the radconfirm to open even before the form gets processed based on the current node value. Also I have created a link button to do postback based on the radconfirm clicked value. It also works fine. But the main problem is the form gets processed with the current clicked node and then the radconfirm box opens up. I don't know if the RadAjaxmanager is causing some problem. I have attached the code for reference. Anyone who can help me with this will be highly appreciated.
Also I have seen the kb articles for radtreeview but I don't know if that suits my scenario.
function confirmCallBackFn(arg) {
  
if (arg == true) {
  
__doPostBack("<%= DummyButton.ClientID %>", "");
  
}
  
if (arg == false) {
  
return; 
  
}
  
}
  
<telerik:RadAjaxManager ID="AppRadAjaxManager" runat="server">
  
<AjaxSettings>
  
  
      
<telerik:AjaxSetting AjaxControlID="SearchTreeView" EventName="NodeClick">
  
<UpdatedControls>
  
<telerik:AjaxUpdatedControl ControlID="DetailFormPanel" LoadingPanelID="DetailsAjaxLoadingPanel" UpdatePanelRenderMode="Inline" />
  
<telerik:AjaxUpdatedControl ControlID="Icto_No" UpdatePanelRenderMode="Inline" />
  
<telerik:AjaxUpdatedControl ControlID="AppVerID" UpdatePanelRenderMode="Inline" />
  
</UpdatedControls>
  
</telerik:AjaxSetting>
  
  
</AjaxSettings>
  
<ClientEvents OnRequestStart="RequestStart" OnResponseEnd="ResponseEnd" />
  
</telerik:RadAjaxManager>
  
<telerik:RadAjaxLoadingPanel ID="DetailsAjaxLoadingPanel" Skin="Vista" runat="server">
  
</telerik:RadAjaxLoadingPanel>

 

 

 

This is the dummy control defintion for doing postback on radconfirm values:

 

<asp:LinkButton ID="DummyButton" CausesValidation="false" Text="" Width="0" runat="server" />
Code Behind:

If

 

DoDataCompare() Then AppRadAjaxManager.ResponseScripts.Add("radconfirm('Are you sure you want to navigate to a different node without saving your data?', confirmCallBackFn,330,100,null,'Save Changes?');")

 

 


DoDataCompare will compare and return if there is a change occured in the form. If yes then only i want to show the radconfirm popup.I'm doing some processing after the above code block. So the problem is radconfirm popup doesn't popup at this time and only pop's up after the other code i have written under it. I have also tried the radconfirm block current code execution and it doesn't help either. This is my radwindow manager and block current code definitions:

<telerik:RadWindowManager ShowContentDuringLoad="false" ID="RadWindowManager" Behaviors="Close, Move, Pin" ReloadOnShow="true" VisibleStatusbar="false" runat="server">
  
<Windows>
  
<telerik:RadWindow ID="RadWindow" Modal="true" Behaviors="Close, Move, Pin" Width="925px" Height="700px" runat="server"></telerik:RadWindow>
  
</Windows>
  
</telerik:RadWindowManager>
  
<script type="text/javascript">
  
//MAKE SURE THAT THE FOLLOWING SCRIPT IS PLACED AFTER THE RADWINDOWMANAGER DECLARATION
  
//Replace old radconfirm with a changed version. 
  
var oldConfirm = radconfirm;
  
//TELERIK
  
//window.radconfirm = function(text, mozEvent)
  
//We will change the radconfirm function so it takes all the original radconfirm attributes
  
window.radconfirm = function(text, mozEvent, oWidth, oHeight, callerObj, oTitle) {
  
var ev = mozEvent ? mozEvent : window.event; //Moz support requires passing the event argument manually 
  
//Cancel the event 
  
ev.cancelBubble = true;
  
ev.returnValue = false;
  
if (ev.stopPropagation) ev.stopPropagation();
  
if (ev.preventDefault) ev.preventDefault();
  
//Determine who is the caller 
  
var callerObj = ev.srcElement ? ev.srcElement : ev.target;
  
//Call the original radconfirm and pass it all necessary parameters 
  
if (callerObj) {
  
//Show the confirm, then when it is closing, if returned value was true, automatically call the caller's click method again. 
  
var callBackFn = function(arg) {
  
if (arg) {
  
callerObj["onclick"] = "";
  
if (callerObj.click) callerObj.click(); //Works fine every time in IE, but does not work for links in Moz 
  
else if (callerObj.tagName == "A") //We assume it is a link button! 
  
{
  
try {
  
eval(callerObj.href)
  
}
  
catch (e) { }
  
}
  
}
  
}
  
//TELERIK
  
//oldConfirm(text, callBackFn, 300, 100, null, null); 
  
//We will need to modify the oldconfirm as well 
  
oldConfirm(text, callBackFn, oWidth, oHeight, callerObj, oTitle);
  
}
  
return false;
  
  
</script>
I have placed the block execution code after radwindowmanager as per the kb article but in that case the radconfirm doesn't popup. If i remove then it pops up. Also here is the code for the dummy control that does a postback:

 

Protected

 

Sub DummyButton_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles DummyButton.Click

 

 

 

End Sub

 

 

I know I have wriiten a big story but i want to explain to the fullest so that whoever lokks at this won't get confused. Can anyone help me with why the code after radconfirm gets executed? I want the code to get executed only when the user clicks CANCEL and the code in the postback when the user clicks OK. 
Thanks & Regards,
Ratish

Dimitar Terziev
Telerik team
 answered on 09 Dec 2010
3 answers
237 views
This is very strange. When I run the site from VS Studio in debug mode, all disply properly on the Grid with the default theme. When I deploy the site to the server, the edit and delete button image not showing. However, add and refresh button seems to disaplay fine. I noticed that when I deploy, it doesn't copy over Telerik.Web.Design.dll file with it, only Telerik.Web.UI.dll and Telerik.Web.UI.xml to the bin folder. But even if I copy it over manually, it doesn't solve the problem. I have both dll in the reference, not sure why VS didn't include Telerik.Web.Design.dll in the deployment file. I am using .NET 4.0.

Thanks a lot!
Iana Tsolova
Telerik team
 answered on 09 Dec 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?