Click here to Skip to main content
15,886,110 members
Home / Discussions / C#
   

C#

 
AnswerRe: Calling an event to a class in a different namespace Pin
Not Active1-Apr-10 6:37
mentorNot Active1-Apr-10 6:37 
QuestionError loading XML data Pin
billy_iii1-Apr-10 3:23
billy_iii1-Apr-10 3:23 
AnswerRe: Error loading XML data Pin
Garry J Evans1-Apr-10 6:19
Garry J Evans1-Apr-10 6:19 
GeneralRe: Error loading XML data Pin
billy_iii6-Apr-10 1:43
billy_iii6-Apr-10 1:43 
GeneralRe: Error loading XML data Pin
Garry J Evans6-Apr-10 2:54
Garry J Evans6-Apr-10 2:54 
QuestionDo I need to Dispose LINQ To SQL Data Context ? Pin
Nadia Monalisa1-Apr-10 1:35
Nadia Monalisa1-Apr-10 1:35 
AnswerRe: Do I need to Dispose LINQ To SQL Data Context ? Pin
R. Giskard Reventlov1-Apr-10 1:41
R. Giskard Reventlov1-Apr-10 1:41 
GeneralRe: Do I need to Dispose LINQ To SQL Data Context ? Pin
Nadia Monalisa1-Apr-10 7:22
Nadia Monalisa1-Apr-10 7:22 
Hi,
Thanks a lot for your reply. I have following code in my ASP.NET page. I am wondering If it is more efficient to place the line SpDBDataContext myDbContext = new SpDBDataContext(); globally and override the Page's Dispose method and call the myDbContext.Dispose() method inside that Disposer !!


<br />
      protected void _linqDataSourceProductsFirst_Selecting(object sender, LinqDataSourceSelectEventArgs e)<br />
      {<br />
            using (SpDBDataContext myDbContext = new SpDBDataContext())<br />
            {<br />
                var productResults = myDbContext.products.Where(x => emran.publish).OrderBy(x => x.isFeatured);<br />
               e.Result = productResults;<br />
            }<br />
     }<br />



This linqDataSourceProductsFirst is a LinQDataSource control placed in ASP.NET page.
AnswerRe: Do I need to Dispose LINQ To SQL Data Context ? Pin
Not Active1-Apr-10 1:46
mentorNot Active1-Apr-10 1:46 
GeneralRe: Do I need to Dispose LINQ To SQL Data Context ? [modified] Pin
Nadia Monalisa1-Apr-10 7:14
Nadia Monalisa1-Apr-10 7:14 
GeneralRe: Do I need to Dispose LINQ To SQL Data Context ? Pin
Not Active1-Apr-10 7:34
mentorNot Active1-Apr-10 7:34 
GeneralRe: Do I need to Dispose LINQ To SQL Data Context ? Pin
Nadia Monalisa1-Apr-10 8:00
Nadia Monalisa1-Apr-10 8:00 
GeneralRe: Do I need to Dispose LINQ To SQL Data Context ? Pin
Not Active1-Apr-10 8:24
mentorNot Active1-Apr-10 8:24 
QuestionSelecting everything with CTRL+A Pin
teknolog1231-Apr-10 0:55
teknolog1231-Apr-10 0:55 
AnswerRe: Selecting everything with CTRL+A Pin
Mohammad Elsheimy1-Apr-10 1:14
Mohammad Elsheimy1-Apr-10 1:14 
AnswerRe: Selecting everything with CTRL+A Pin
Khaniya1-Apr-10 1:32
professionalKhaniya1-Apr-10 1:32 
GeneralRe: Selecting everything with CTRL+A Pin
teknolog1231-Apr-10 1:57
teknolog1231-Apr-10 1:57 
AnswerRe: Selecting everything with CTRL+A Pin
teknolog1231-Apr-10 1:52
teknolog1231-Apr-10 1:52 
GeneralRe: Selecting everything with CTRL+A Pin
Khaniya1-Apr-10 2:52
professionalKhaniya1-Apr-10 2:52 
QuestionDifferent number of overloaded constructors for same class in different computers [modified] Pin
free young1-Apr-10 0:31
free young1-Apr-10 0:31 
AnswerRe: Different number of overloaded constructors for same class in different computers Pin
Tej Aj1-Apr-10 1:36
Tej Aj1-Apr-10 1:36 
GeneralRe: Different number of overloaded constructors for same class in different computers Pin
free young1-Apr-10 18:21
free young1-Apr-10 18:21 
AnswerRe: Different number of overloaded constructors for same class in different computers Pin
PIEBALDconsult1-Apr-10 3:44
mvePIEBALDconsult1-Apr-10 3:44 
GeneralRe: Different number of overloaded constructors for same class in different computers Pin
free young1-Apr-10 18:25
free young1-Apr-10 18:25 
QuestionSimple Passing of Values Pin
Steve-Co31-Mar-10 23:56
Steve-Co31-Mar-10 23:56 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.