Setting x-microsoftajax: Delta=true header is giving http error 400
-
hi all, i am posting some url to server through http request which returns result in updatepanel control so it requires me to add "x-microsoftajax: Delta=true header, but it returns me error code 400... but if i remove this header i get the page but without that updatepanel which contains the required data for me....please can anyone assist me on this.
Thanks A Ton Ash_VCPP walking over water is just knowing where the stones are.....
-
hi all, i am posting some url to server through http request which returns result in updatepanel control so it requires me to add "x-microsoftajax: Delta=true header, but it returns me error code 400... but if i remove this header i get the page but without that updatepanel which contains the required data for me....please can anyone assist me on this.
Thanks A Ton Ash_VCPP walking over water is just knowing where the stones are.....
Are you using XmlHttpRequest for this?? I think what asp.NET does... from within the updatepanel.. if a request is made. the postback is suppressed and AJAX page creates an XMLHttpRequest object and places the special request with
x-microsoft: Delta=true
and receives only the part of data which corresponds to the update panel.. This is purely an AJAX request and the output you get from those request will not hold the entire page. If are putting your custom request by making an object of XMLHttpRequest yourself, you need to know what are the other things that the request must contain before this could get an output. This is purely a custom request made by Microsoft. 400 means bad request or Page doesnt exists... Thus rather than making this type of request, it is always better to expose the data in one page and make a call normally to it. Tweaking between custom forms and viewstate entries is not always good... (At least who knows this internal form structure might change in next version ofUpdatePanel
) :cool:Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.
-
Are you using XmlHttpRequest for this?? I think what asp.NET does... from within the updatepanel.. if a request is made. the postback is suppressed and AJAX page creates an XMLHttpRequest object and places the special request with
x-microsoft: Delta=true
and receives only the part of data which corresponds to the update panel.. This is purely an AJAX request and the output you get from those request will not hold the entire page. If are putting your custom request by making an object of XMLHttpRequest yourself, you need to know what are the other things that the request must contain before this could get an output. This is purely a custom request made by Microsoft. 400 means bad request or Page doesnt exists... Thus rather than making this type of request, it is always better to expose the data in one page and make a call normally to it. Tweaking between custom forms and viewstate entries is not always good... (At least who knows this internal form structure might change in next version ofUpdatePanel
) :cool:Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.
Hi Abhishek, Thanks for the reply.. but what about it "but if i remove this header(x-microsoftajax: Delta=true ) i get the page but without that updatepanel which contains the required data for me....." Yes i am using HTTPRequest object. so as you said i should try to send httprequest without view source and other stuff but can you explain it a bit more that what i should exactly do.
Thanks A Ton Ash_VCPP walking over water is just knowing where the stones are.....