Пример #1
0
 public bool DeleteImageGallery(imagegallery obj)
 {
     try
     {
         imagegallery objimagegallery = dbcontext.imagegalleries.Where(t => t.imageid == obj.imageid).FirstOrDefault();
         dbcontext.imagegalleries.DeleteOnSubmit(objimagegallery);
         dbcontext.SubmitChanges();
         return true;
     }
     catch (Exception)
     {
         return false;
     }
 }
Пример #2
0
    public bool UpdateImageGalleryWithoutImage(imagegallery obj)
    {
        try
        {
            imagegallery objimagegallery = dbcontext.imagegalleries.Where(t => t.imageid == obj.imageid).FirstOrDefault();

            objimagegallery.eventid = obj.eventid;
            objimagegallery.postdate = obj.postdate;

            return true;
        }
        catch (Exception)
        {
            return false;
        }

    }
Пример #3
0
    public bool InsertImageGallery(imagegallery obj)
    {
        try
        {
            dbcontext.imagegalleries.InsertOnSubmit(obj);
            dbcontext.SubmitChanges();
            return true;
        }
        catch (Exception)
        {
            return false;
        }

    }
Пример #4
0
 partial void Deleteimagegallery(imagegallery instance);
Пример #5
0
 partial void Updateimagegallery(imagegallery instance);
Пример #6
0
 partial void Insertimagegallery(imagegallery instance);