TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Sie Ste
NA
196
184k
data context object in web app 2010
Jun 24 2012 2:00 PM
I am asking this question since this is the first C#.net 2010 web form application that I am writing. In this application I am using linq to sql to connect to a sql server 2008 r2 database since that is what the rest of the web pages do in this application.
My question is on one particular web form page, I have been creating new datacontexts objects for each button that is used on this web form page. All these data context objects refer to the same .dbml file.
Thus I am wondering if I should use only one data context object and put that creation of the data context object on top of the web page and give it a protected web form page access?
Can you tell me and/or point me to a reference that will tell me what the best way is to handle this situation and show me how to accomplish this task in code?
Reply
Answers (
1
)
custom validator for C# web app
OUR RECOMMENDED FORUM POSTS