Ajai Ajai

Ajai Ajai

  • NA
  • 120
  • 0

regarding using statement

May 5 2016 3:09 PM
I have just a stupid question in mind, but i need answer. if i am using "using" statement in c# then its automatically handle try, catch, and finally statement, but if we use "return" statement in try block then its automatically dispose or not before or after return.
Sample code is above
using(dbContext db = new dbContext())
{
return db.users.tolist();
}

Answers (2)