Following is the flex code to import a csv data file via c# webservice.
private function Import():void{
    CursorManager.setBusyCursor();
    var op:Operation = Operation(_webservice.getOperation('ImportData'));
    op.addEventListener(FaultEvent.FAULT,operationFault);
    op.addEventListener(ResultEvent.RESULT,operationResult);
    var ba:ByteArray = new ByteArray();
    ba.writeUTFBytes(objectToXML开发者_如何学编程(datasource.source).toXMLString());
    op.arguments = new Array(filename, ba);
    op.send();
}
protected function operationFault(e:FaultEvent):void
{
    CursorManager.removeBusyCursor();
    Alert.show(e.fault + " (" + e.statusCode + ")");
}
protected function operationResult(e:ResultEvent):void
{
    datasource.removeAll();
    CursorManager.removeBusyCursor();
    Alert.show("Success");
}
and following is the c# webservice:
[WebMethod]
public XmlDocument ImportData(String filename, byte[] data)
{
    Boolean bReturn = false;
    /* .... code to import data .... */
    XmlDocument xmlDoc = new XmlDocument();
    xmlDoc.LoadXml("<response>" + (bReturn ? "true" : "false") + "</response>");
    conn.Close();
    return xmlDoc;
}
The application works fine on my development environment, whereas when I run it on the production server I get the following error message:
[RPC Fault faultString="SOAP Response Version Mismatch" faultCode="DecodingError" faultDetail="null"] (404)
Development Environment is: Win7, MSSQL Server 2005, MS Visual Studio 2010, .NET Framework version 4.0.30319
Live Server: Win2008 Server, MSSQL Server 2005, IIS7, .NET Framework version 4.0.30319
Can anyone think of a reason regarding why I get the error message above on the live server?
Thanks.
I figured the problem. The data file I was trying to import was of 7MB text file. I split it into 2 files and tried to import then it worked. So the problem was the size of the data being transferred to the server.
 
         
                                         
                                         
                                         
                                        ![Interactive visualization of a graph in python [closed]](https://www.devze.com/res/2023/04-10/09/92d32fe8c0d22fb96bd6f6e8b7d1f457.gif) 
                                         
                                         
                                         
                                         加载中,请稍侯......
 加载中,请稍侯......
      
精彩评论