예제 #1
0
 public string UpdateNews(News news)
 {
     try
     {
         Business business = new Business();
         return business.UpdateNews(news);
     }
     catch (Exception ex)
     {
         return ex.Message;
     }
 }
예제 #2
0
 public void UpdateNews(News news)
 {
     int maxId = GetMaxId("tblNews", "Id") + 1;
     string query = "INSERT INTO [tblNews]([Id],[NewsHeader],[NewsContent])VALUES(" + maxId + ",'" + news.NewsHeader + "','" + news.NewsDetails + "');";
     ExecuteNonQuery(query);
 }
예제 #3
0
 public string UpdateNews(News news)
 {
     dataAccess.UpdateNews(news);
     return "OK";
 }