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

C#

 
GeneralRe: Create Instance or invoke members of a class from a loaded assembly Pin
Danzy8322-Sep-12 4:18
Danzy8322-Sep-12 4:18 
GeneralRe: Create Instance or invoke members of a class from a loaded assembly Pin
Eddy Vluggen22-Sep-12 5:01
professionalEddy Vluggen22-Sep-12 5:01 
AnswerRe: Create Instance or invoke members of a class from a loaded assembly Pin
jschell22-Sep-12 8:44
jschell22-Sep-12 8:44 
AnswerRe: Create Instance or invoke members of a class from a loaded assembly Pin
BobJanova24-Sep-12 0:52
BobJanova24-Sep-12 0:52 
QuestionC# Application With MS Access Pin
SUBODH.SB21-Sep-12 23:39
SUBODH.SB21-Sep-12 23:39 
AnswerRe: C# Application With MS Access Pin
Eddy Vluggen22-Sep-12 2:56
professionalEddy Vluggen22-Sep-12 2:56 
AnswerRe: C# Application With MS Access Pin
Smart Arab23-Sep-12 10:39
Smart Arab23-Sep-12 10:39 
QuestionC# linq problem Pin
classy_dog21-Sep-12 11:38
classy_dog21-Sep-12 11:38 
I am working in a C# 2010 application where I have written the following lines of linq to sql code:
int TotCount = 0;            
string[] PkgIDs = rptData.Transaction.Where(c =>c.Package_ID.StartsWith("rva") &&
                                c.Received_Date != null ).Select(c => c.Package_ID).ToArray();
            foreach (string PkgID in PkgIDs)
            {
                var eCnt =  rptData.Details.Where(c =>c.Package_ID == PkgID).Select(c =>c.TotalTrans);
                TotCount = Convert.ToInt32(eCnt);
            }


My problem line of code is:    var eCnt =  rptData.Details.Where(c =>c.Package_ID == PkgID).Select(c =>c.TotalTrans);

I want to be able to obtain the value contained in the c.TotalTrans field and place the value in the eCnt field.

When I am stepping through the code and go to the line right after the line I listed above, I only see the sql equivalent value. I want to see the value for c.TotalTrans in the eCnt field.

I know what I need now is to actually make the linq to sql statement actually execute. That would be similar to the 'ToArray()'
statement listed above. However, I do not know what to change in the statement to actually obtain the value.

Thus can you tell me what else I need to add to this statement so that I get my desired
AnswerRe: C# linq problem Pin
Matt T Heffron21-Sep-12 13:18
professionalMatt T Heffron21-Sep-12 13:18 
Questionputting VS projects/solutions in a TFS team project Pin
chuckdawit21-Sep-12 7:58
chuckdawit21-Sep-12 7:58 
AnswerRe: putting VS projects/solutions in a TFS team project Pin
Emmanuel Medina21-Sep-12 11:30
professionalEmmanuel Medina21-Sep-12 11:30 
GeneralRe: putting VS projects/solutions in a TFS team project Pin
chuckdawit21-Sep-12 11:52
chuckdawit21-Sep-12 11:52 
QuestionMonoDroid Pin
mAzeem2221-Sep-12 5:55
mAzeem2221-Sep-12 5:55 
AnswerRe: MonoDroid Pin
Emmanuel Medina21-Sep-12 11:34
professionalEmmanuel Medina21-Sep-12 11:34 
GeneralRe: MonoDroid Pin
mAzeem2221-Sep-12 19:57
mAzeem2221-Sep-12 19:57 
GeneralRe: MonoDroid Pin
Richard MacCutchan21-Sep-12 21:15
mveRichard MacCutchan21-Sep-12 21:15 
QuestionC# using linq Pin
classy_dog21-Sep-12 5:53
classy_dog21-Sep-12 5:53 
AnswerRe: C# using linq Pin
Eddy Vluggen21-Sep-12 6:14
professionalEddy Vluggen21-Sep-12 6:14 
GeneralRe: C# using linq Pin
Paul Conrad22-Sep-12 11:19
professionalPaul Conrad22-Sep-12 11:19 
QuestionSend commands to DOS using C# Pin
kirangowle21-Sep-12 5:25
kirangowle21-Sep-12 5:25 
AnswerRe: Send commands to DOS using C# Pin
Thomas Daniels21-Sep-12 5:30
mentorThomas Daniels21-Sep-12 5:30 
QuestionSql Connection Problem in IIS Server Pin
omgade21-Sep-12 1:45
omgade21-Sep-12 1:45 
AnswerRe: Sql Connection Problem in IIS Server Pin
Shameel21-Sep-12 1:58
professionalShameel21-Sep-12 1:58 
QuestionCrystal Report Not Working For Console Application Pin
idreesbadshah21-Sep-12 0:09
idreesbadshah21-Sep-12 0:09 
AnswerRe: Crystal Report Not Working For Console Application Pin
Ingo21-Sep-12 1:10
Ingo21-Sep-12 1:10 

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.