Click here to Skip to main content
14,692,052 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi,

I want to pass the byte array into insert query but I am not using the parameter. I am directly passing values into insert query.
I am getting the following error:
at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
   at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)

from 
System.Web.Services
The request failed with HTTP status 400: Bad Request.

my code
object str;
System.Text.UTF8Encoding enc = new System.Text.UTF8Encoding();
str = enc.GetString(image);

objGL.GetSelectByQuery("update empmast set photo=convert(varbinary(MAX),'" + str + "') where srno='" + txtSRNO.Text + "'");

Any help is greatly appreciated.
Posted
Updated 18-May-11 1:32am
v4
Comments
Slacker007 18-May-11 6:30am
   
Edited for spelling, grammar, and readability.
Keith Barrow 18-May-11 11:08am
   
Can you get the request you client makes to the server you can download and use Fiddler to do this.

http://www.fiddler2.com/fiddler2/

1 solution

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900