1
我在通过ajax调用将大量数据从.js文件发布到.cs文件时遇到问题。Ajax-Post-Data-maxJsonLength属性限制在javascript文件中执行
错误是“使用JSON JavaScriptSerializer进行序列化或反序列化时出错,字符串长度超过了maxJsonLength属性设置的值”。
$http({
url: exportexcelurl,
method: 'post',
data:JSON.stringify({componentid:componentid,city_id:cityid,industrysegment: indsegmentid, wf_activity: wf_activity_id, user: users }),
headers: {
"content-type": "application/json"
}
}).success(function (response) {
var downloadfileurl = webAppBase + "softcopyupload/download";
window.location = downloadfileurl + '?filename=' + response;
}).error(function (error) {
});