SqlParameter[] paramList = new SqlParameter[]{
new SqlParameter ("@vcApplicationConstName", "abc"),
new SqlParameter ("@iApplicationID", SqlDbType.VarChar,50),
new SqlParameter ("@Return", SqlDbType.Int)
};
((SqlParameter)paramList[1]).Direction = ParameterDirection.Output;
((SqlParameter)paramList[2]).Direction = ParameterDirection.ReturnValue ;
int a= SQLHelper.ExecuteNonQuery(conn, CommandType.StoredProcedure, "sp_BSQ_GetApplicationID", paramList);
Response.Write(a);
Response.Write("
iApplicationID=");
Response.Write(((SqlParameter)paramList[1]).Value);
Response.Write("
Returnvalue=");
Response.Write(((SqlParameter)paramList[2]).Value);
參考網址:http://www.mugua.net/vbgl/com/205004.htm
沒有留言:
張貼留言