1、WCF 序列化 DataTable 问题
Error:
"An error occurred while receiving the HTTP response to ****.svc. This could be due to the service endpoint binding not using the HTTP protocol. ……"
Methods:
在返回DataTable的GetTableAllData方法中, tableResult设置了TableName属性。这样Wcf序列化时就不会出错。
而返回DataSet的方法不需要作任何设置。
DataTable tableResult = null;
tableResult = msSql.GetTableAllData(tableName);
tableResult.TableName = "navigateData";
return tableResult;