public IHttpActionResult DeleteProposalDocument(Int64 documentID) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } CRUDOperation cRUDOperation = new CRUDOperation(); tbl_ProposalDocument dbitem = cRUDOperation.DeleteProposalDocument(documentID, 0); if (dbitem != null) { return(Ok(dbitem)); } else { return(BadRequest("404" + " : " + "An error occurred while deleting the record ")); } }