wpf - Add record to DB using LINQ to SQL? dont save record in DB -


i using using linq sql. when adding new record db show add taking record, close app , go db, no record were, if add manualy in db , retrieve data.

why can retrieve data, not save data add.

my add method

   public void insertkelias(kelias kelias)     {         db13datacontext context = new db13datacontext();         context.kelias.insertonsubmit(kelias);         context.submitchanges();     } 

get data metod

    public list<kelias> kelias()     {         db13datacontext context = new db13datacontext();         return  context.kelias.tolist();;     }       


Comments

Popular posts from this blog

java - Jmockit String final length method mocking Issue -

asp.net - Razor Page Hosted on IIS 6 Fails Every Morning -

c++ - wxwidget compiling on windows command prompt -