public string DoInsertTravels(string proc,string travelsname) { try { mDbconnection = conn.GetDefaultDbConnectionString(); using (SqlCommand cmd = new SqlCommand(proc, mDbconnection)) { string Result = string.Empty; cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add("@Travelsname", SqlDbType.NVarChar, 150).Value = travelsname; cmd.Parameters.Add("@Result", SqlDbType.NVarChar, 500).Direction = ParameterDirection.Output; cmd.ExecuteNonQuery(); return Result = cmd.Parameters["@Result"].Value.ToString(); ; } } catch { throw; } finally { mDbconnection.Close(); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)