public void disaster_delete(int ID) { disaster.Delete(ID); Insert_disaster_GridView.DataBind(); Update_disaster_GridView.DataBind(); Delete_disaster_GridView.DataBind(); }
public disaster disaster_insert() { disaster.disaster_name = Insert_disaster_name_txt.Text; disaster.disaster_type = Insert_disaster_type_txt.Text; disaster.disaster_start_date = Convert.ToDateTime(Insert_disaster_start_date_txt.Text); disaster.disaster_end_date = Convert.ToDateTime(Insert_disaster_end_date_txt.Text); disaster.disaster_north_latitude = Convert.ToDecimal(Insert_disaster_north_latitude_txt.Text); disaster.disaster_north_longitude = Convert.ToDecimal(Insert_disaster_north_longitude_txt.Text); disaster.disaster_south_latitude = Convert.ToDecimal(Insert_disaster_south_latitude_txt.Text); disaster.disaster_south_longitude = Convert.ToDecimal(Insert_disaster_south_longitude_txt.Text); disaster.disaster_east_latitude = Convert.ToDecimal(Insert_disaster_east_latitude_txt.Text); disaster.disaster_east_longitude = Convert.ToDecimal(Insert_disaster_east_longitude_txt.Text); disaster.disaster_west_latitude = Convert.ToDecimal(Insert_disaster_west_latitude_txt.Text); disaster.disaster_west_longitude = Convert.ToDecimal(Insert_disaster_west_longitude_txt.Text); disaster = disaster.Insert(disaster); Insert_disaster_GridView.DataBind(); Update_disaster_GridView.DataBind(); Delete_disaster_GridView.DataBind(); return(disaster); }
public disaster disaster_update(int ID) { disaster = disaster.Select(ID); disaster.disaster_id = Convert.ToInt32(Update_disaster_id_txt.Text); disaster.disaster_name = Update_disaster_name_txt.Text; disaster.disaster_type = Update_disaster_type_txt.Text; disaster.disaster_start_date = Convert.ToDateTime(Update_disaster_start_date_txt.Text); disaster.disaster_end_date = Convert.ToDateTime(Update_disaster_end_date_txt.Text); disaster.disaster_north_latitude = Convert.ToDecimal(Update_disaster_north_latitude_txt.Text); disaster.disaster_north_longitude = Convert.ToDecimal(Update_disaster_north_longitude_txt.Text); disaster.disaster_south_latitude = Convert.ToDecimal(Update_disaster_south_latitude_txt.Text); disaster.disaster_south_longitude = Convert.ToDecimal(Update_disaster_south_longitude_txt.Text); disaster.disaster_east_latitude = Convert.ToDecimal(Update_disaster_east_latitude_txt.Text); disaster.disaster_east_longitude = Convert.ToDecimal(Update_disaster_east_longitude_txt.Text); disaster.disaster_west_latitude = Convert.ToDecimal(Update_disaster_west_latitude_txt.Text); disaster.disaster_west_longitude = Convert.ToDecimal(Update_disaster_west_longitude_txt.Text); disaster.Update(disaster); Insert_disaster_GridView.DataBind(); Update_disaster_GridView.DataBind(); Delete_disaster_GridView.DataBind(); return(disaster); }