Telerik Forums
UI for ASP.NET AJAX Forum
7 answers
148 views
Hi Rad Team,

we are using a RadComboBox in an RadAjaxPanel and we have some issues in Firefox 3. In IE7 the page works perfectly, but in FF3 after the SelectedItem changed and the ajax call comes back there is problem, the ComboBox freezes and (other possibly RadControls in the same Panel).

Firebug reported me following problem:

uncaught exception: The container of an boundary-point of a range is being set to either a node of an invalid type or a node with an ancestor of an invalid type. (NS_ERROR_DOM_RANGE_INVALID_NODE_TYPE_ERR)

It also states this exception happens in line 8340 of the follwong code:

8216//////////////////////// IE functionality for Mozilla/Netscape ///////////////////////////////
8217 // make Mozilla browsers emulate IE's node/element functionality
8218if (isNav) {
8219 Element.prototype.contains = function(element){
8220 var range=document.createRange();
8221 range.selectNode(this);
8222 return range.compareNode(element)==3;
8223 }
8224
8225 Element.prototype.applyElement = function(element, where){
8226 if(!element.splitText){
8227 element.removeNode();
8228 if(where && where.toLowerCase()=="inside"){
8229 for(var i=0;i<this.childNodes.length;i++){
8230 element.appendChild(this.childNodes[i])
8231 }
8232 this.appendChild(element)
8233 }else{
8234 var parent_Node=this.parentNode;
8235 parent_Node.insertBefore(element,this);
8236 element.appendChild(this);
8237 }
8238 return element;
8239 }
8240 }
8241
8242 Element.prototype.insertAdjacent=function(where, element){
8243 var parent_Node=this.parentNode;
8244 switch(where.toLowerCase()) {
8245 case "beforebegin":
8246 parent_Node.insertBefore(element,this);
8247 break;
8248 case "afterend":
8249 parent_Node.insertBefore(element,this.nextSibling);
8250 break;
8251 case "afterbegin":
8252 this.insertBefore(element,this.childNodes[0]);
8253 break;
8254 case "beforeend":
8255 this.appendChild(element);
8256 break;
8257 }
8258 }
8259
8260 Element.prototype.insertAdjacentText = function(where, text){
8261 var text_Node=document.createTextNode(text||"")
8262 this.insertAdjacent(where, text_Node);
8263 }
8264
8265 Element.prototype.insertAdjacentHTML = function(where, html){
8266 var range=document.createRange();
8267 range.selectNode(this);
8268 var fragment=range.createContextualFragment(html);
8269 this.insertAdjacent(where, fragment);
8270 }
8271
8272 Element.prototype.insertAdjacentElement = function(where,element){
8273 this.insertAdjacent(where,element);
8274 return a2;
8275 }
8276
8277// Node.prototype.removeNode = function (node){
8278// var parent_Node=this.parentNode;
8279// if(parent_Node && !node){
8280// var fragment=document.createDocumentFragment();
8281// for(var i=0;i<this.childNodes.length;i++){
8282// fragment.appendChild(this.childNodes[i])
8283// }
8284// parent_Node.insertBefore(fragment,this)
8285// }
8286// return parent_Node ? parent_Node.removeChild(this):this;
8287// }
8288
8289 Node.prototype.removeNode = function( removeChildren ) {
8290 var self = this;
8291 if ( Boolean( removeChildren ) )
8292 {
8293 return this.parentNode.removeChild( self );
8294 }
8295 else
8296 {
8297 var range = document.createRange();
8298 range.selectNodeContents( self );
8299 return this.parentNode.replaceChild( range.extractContents(), self );
8300 }
8301 }
8302
8303 Node.prototype.replaceNode = function (node){
8304 return this.parentNode.replaceChild(node,this)
8305 }
8306
8307 Node.prototype.swapNode=function(node){
8308 var parent_Node=node.parentNode;
8309 var next_Sibling=node.nextSibling;
8310 this.parentNode.replaceChild(node,this);
8311 parent_Node.insertBefore(this, next_Sibling)
8312 return this;
8313 }
8314
8315 // outerHTML implementation
8316 var _emptyTags = {
8317 "IMG": true,
8318 "BR": true,
8319 "INPUT": true,
8320 "META": true,
8321 "LINK": true,
8322 "PARAM": true,
8323 "HR": true
8324 };
8325
8326 HTMLElement.prototype.__defineGetter__("outerHTML", function () {
8327 var attrs = this.attributes;
8328 var str = "<" + this.tagName;
8329 for (var i = 0; i < attrs.length; i++)
8330 str += " " + attrs[i].name + "=\"" + attrs[i].value + "\"";
8331
8332 if (_emptyTags[this.tagName])
8333 return str + ">";
8334
8335 return str + ">" + this.innerHTML + "</" + this.tagName + ">";
8336 });
8337
8338 HTMLElement.prototype.__defineSetter__("outerHTML", function (sHTML) {
8339 var r = this.ownerDocument.createRange();
8340 r.setStartBefore(this);
8341 var df = r.createContextualFragment(sHTML);
8342 this.parentNode.replaceChild(df, this);
8343 });
8344
8345}

Do you have any idea for fixing this?

Thanks, Stefan



Andrea Doberstein
Top achievements
Rank 1
 answered on 15 Jan 2010
2 answers
155 views
Hi,

In your demo http://demos.telerik.com/aspnet-ajax/fileexplorer/examples/default/defaultvb.aspx, when clicking " " the paging slider and info (page 1 of ....) becomes visible.
When I set "AllowPaging=true" only the slider is visible and not the information block.

I also set

RadFileExplorer1.Grid.PagerStyle.PagerTextFormat = "Change page: {4} | Displaying page {0} of {1}, items {2} to {3} of {5}."

but it doesn't help.

Marc



Fit2Page
Top achievements
Rank 3
Bronze
Bronze
Iron
 answered on 15 Jan 2010
1 answer
148 views
Hi,

I have a fairly complex UI in my application and have decided to take the approach outlined in http://www.telerik.com/help/aspnet-ajax/ajxchangecursor.html

This approach works partially in that the hourglass does appear during the AJAX call;  however when the mouse is moved around during the AJAX call, the specified cursor is overridden whenever the mouse is positioned over asp:CheckBox or telerik:RadTextBox controls.

I was able to fix the situation for the checkboxes by dynamically changing/appending to the CSS class using http://stackoverflow.com/questions/195951/change-an-elements-css-class-with-javascript as inspiration but the RadTextBox controls ignore the new styles.

Is there a better approach to have the updated cursor apply to the body and all of it's child controls?

Thanks,

Dave
Dimo
Telerik team
 answered on 15 Jan 2010
6 answers
129 views
I've used the export to PDF from a simple grid and it works great.

My question pertains to using Export to PDF from a hierarchical grid with some additional complications.  I have a page (see attachment) which has not only a hierarchical grid but a summary section that sums data from the grid.  I'd like to throw all that info to a PDF.

Does the Grid based Export to PDF allow one to modify the contents of the output file by adding additional information such as I have here in my summary section?  I can't find any decent example in the help files.

If this is not a feasible solution, what would one do to build a PDF "report" in the middle of this page containing this grid plus summary information?

Thanks much,
JC
John Cooney
Top achievements
Rank 1
 answered on 15 Jan 2010
1 answer
264 views
See the screenshot ; I have a simple "input type=text" control, an asp:Button, and below a RadGrid. You could see that the list of hints displayed by IE is shifted.
Do you have an idea about what could cause that?
Dimo
Telerik team
 answered on 15 Jan 2010
3 answers
172 views
Hi,

I'm using the scheduler to load list of read only appointments. So I set "AllowEdit="false" and also the "ReadOnly" properties of the respective monthview and dayview. It loads fine and displays the appointment.

But when I double click on any cell in the schedule (not on the area where the appointments are displayed but outside it), the page gets reloaded and all appointments are gone.

How do I prevent this?.

Thanks,
Prem
Peter
Telerik team
 answered on 15 Jan 2010
5 answers
96 views
Hi,

I have a problem with IE8 and the RadWindow. I have uploaded a simple project at http://www.smallweb.nl/upload/danny/RadWindowTest.zip.

What I do is the following:
1. I have added a button, label, hyperlink and radwindow to the page
2. The hyperlink opens the RadWindow, using some javascript.
3. Using the add_close function of the RadWindow, a javascript function is called when the RadWindow is closed
4. When the RadWindow is closed, the command $get('Button1').click() method is called, which performs a postback to the server
5. The button is added to the RadAjaxManager as an AjaxControl. The Label is added as an AjaxUpdatedControl.

So when the RadWindow is closed, the button is clicked (using some javascript) and the label will be updated using AJAX. This all works fine in IE7 and FF, but not in IE8. 

Ien IE8, when the RadWindow is opened and closed for the second time on this page, there are two requests for this page at the server. When I set a breakpoint in the page_load event and check the IsPostBack property (which should be set to TRUE), in the 1st request this property is FALSE and also the click event of the button does not occur. In the 2nd request the IsPostBack property is TRUE and the click event occurs.
In IE7 and FF only one request to the server occurs (as it should be).

Is there a workaround for this problem?

Thanks,
Danny
Georgi Tunev
Telerik team
 answered on 15 Jan 2010
1 answer
146 views
In your samples you demonstrate that we nee to return IEnumerable of Appointment Data to the scheduler.

Is there something that runs in between of the scheduler and our web service?

I'm getting the following error when navigating to my web service on our staging environment

Cannot serialize interface System.Collections.Generic.IEnumerable`1[[Telerik.Web.UI.AppointmentData, Telerik.Web.UI, Version=2009.3.1208.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4]].


I've been reading in blogs that we shouldn't be returning IEnuermabl from a web service but rather something that can be serialized and therefore use the toArray method on IEnumerable and return that array.

I think this is the cause of another error I'm seeing when going straight to the page

The remote name could not be resolved: myschedulersite.test.com



thanks


Dimitar Milushev
Telerik team
 answered on 15 Jan 2010
2 answers
133 views

Can anyone tell my why the grid columns would be in a different order on an Export than they are on the Web-Page?

Thank You,
Jim Harkins
Daniel
Telerik team
 answered on 15 Jan 2010
1 answer
440 views
Typing anything close to HTML into a RadTextBox seems to break it when it goes over the wire. I've tried escaping (encoding) it via javascript in the OnRequestStart, but that didn't seem to work... any ideas on the proper way to handle this (and without using a RadEditor).
Dimo
Telerik team
 answered on 15 Jan 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?