[DataObjectMethod(DataObjectMethodType.Insert, true)]
[System.Web.Services.WebMethod(TransactionOption = TransactionOption.Supported)]
[AutoComplete]
public int addVehCategoryType(byte[] VEHIMAGE)
{
SqlParameter[] cmdParm ={
new SqlParameter("@VEHIMAGE", VEHIMAGE),
};
return SQLHelper.ExecuteQueryReturnInt(0, constr,
"[VEH_VEHICLECATEGORY_ADDVEHICLECATEGORY]", cmdParm, true);
}
<asp:FileUpload id="fuCategoryVehImage" runat="server" Width="220px" CssClass="input"
Enabled='<%# Bind("VEHIMAGE") %>'></asp:FileUpload>
I have a web services methods like this, so how would i gonna do inserting images through fileupload extender in my form view?
taekiewzz
0
Newbie Poster
Recommended Answers
Jump to PostThe SQL image datatype is obsolete. Use the SQL binary datatype in the Database table; which is essentially a byte array. You can also use a SQL text datatype and convert the image bytes into a string:
string imageBytesString = Convert.ToBase64String(VEHIMAGE);
Text datatypes cannot be indexed …
All 6 Replies
RvSon
-3
Newbie Poster
geniusvishal
-1
~Coder~
taekiewzz
0
Newbie Poster
taekiewzz
0
Newbie Poster
Maligui
1
Application Developer
taekiewzz
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.