Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Passing image from a VFP app to a .NET web service
Message
De
05/02/2004 21:01:56
Keith Payne
Technical Marketing Solutions
Floride, États-Unis
 
 
À
05/02/2004 05:25:06
Sanero Daniela
Calcol Informatica
Legnano, Italie
Information générale
Forum:
ASP.NET
Catégorie:
Web Services
Divers
Thread ID:
00874347
Message ID:
00874680
Vues:
8
That error code comes from the SoapClient not being able to interpret the correct error returned by .NET. It seems that this happens when there is a type mismatch in the call to the WebMethod (RE: http://support.microsoft.com/?kbid=169565 )

Try oWs.TransferImage(CreateBinary(lcFileStr)), it should work (RE: http://www.west-wind.com/presentations/wchttp.htm )

>I have still problems with the webservice, my try for transfer image from a VFP app to a .NET webservice does not work.
>
>In the .NET webservice I have a webmethod like this
>WebMethod(Description:="Transfer image", EnableSession:=False) _
> Public Sub TransferImage(ByVal buffer As Byte())
> Dim sw As FileStream = New FileStream("c:\test.jpg", FileMode.OpenOrCreate)
> sw.Write(buffer, 0, buffer.Length)
> sw.Close()
> End Sub
>
>in the VFP app I have something like this
>oWs = CREATEOBJECT("MSSOAP.SoapClient")
>oWs.MSSoapInit("http://myservername/myfile.wsdl")
>dimension aArr(1)
>aArr(1) = FILETOSTR("c:\test.jpg")
>* here I have tried to pass the parameter in many way
>oWs.TransferImage(aArr)
>or
>oWs.TransferImage(aArr(1))
>or
>oWs.TransferImage(FILETOSTR("c:\test.jpg"))
>* and I receive an OLE error code 0x80020005
>I have tried also to create a cursor with a binary-memo field and replace it with FILETOSTR("c:\test.jpg"), as suggest from Rick to Jerry, and then I tried to pass it to webservice:
>
>oWs.TransferImage(mycursor.mybinaryfield)
>but I receive always the same OLE error code
>What is wrong?
>
>Thanks in advance
>Daniela
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform