Click here to Skip to main content
15,888,802 members
Home / Discussions / C#
   

C#

 
Rant[REPOST] MySQL Data Synchronisation between Databases in C# Pin
Richard Deeming2-Apr-15 4:42
mveRichard Deeming2-Apr-15 4:42 
QuestionTime out handling in System.Threading.Task class in dotnet 4.0 Pin
Member 113878772-Apr-15 0:11
Member 113878772-Apr-15 0:11 
AnswerRe: Time out handling in System.Threading.Task class in dotnet 4.0 Pin
Pete O'Hanlon2-Apr-15 0:47
mvePete O'Hanlon2-Apr-15 0:47 
AnswerRe: Time out handling in System.Threading.Task class in dotnet 4.0 Pin
Afzaal Ahmad Zeeshan2-Apr-15 1:04
professionalAfzaal Ahmad Zeeshan2-Apr-15 1:04 
QuestionLinq extension method and referencing object? Pin
TMattC1-Apr-15 22:24
TMattC1-Apr-15 22:24 
AnswerRe: Linq extension method and referencing object? Pin
OriginalGriff1-Apr-15 23:47
mveOriginalGriff1-Apr-15 23:47 
GeneralRe: Linq extension method and referencing object? Pin
TMattC2-Apr-15 3:49
TMattC2-Apr-15 3:49 
GeneralRe: Linq extension method and referencing object? Pin
OriginalGriff2-Apr-15 4:05
mveOriginalGriff2-Apr-15 4:05 
Ah! As you say, too little code! Laugh | :laugh:
The thing is that a struct is always a Value type, and a class a Reference type - which means that when you assign a struct instance to another variable you always get a copy, not a reference to the existing one - and it doesn't matter if you do it directly:
C#
ProdTotalSales pn = list[0]
Or via a Linq method:
C#
ProdTotalSales pn = list.First(p => p.Value == 2);
You always get a copy of the data, not a reference to the original item.
I wrote an article on the difference last year: Using struct and class - what's that all about?[^] which may help.
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

GeneralRe: Linq extension method and referencing object? Pin
TMattC2-Apr-15 5:23
TMattC2-Apr-15 5:23 
GeneralRe: Linq extension method and referencing object? Pin
OriginalGriff2-Apr-15 5:47
mveOriginalGriff2-Apr-15 5:47 
GeneralRe: Linq extension method and referencing object? Pin
Simon_Whale2-Apr-15 4:12
Simon_Whale2-Apr-15 4:12 
Questionc# file I/O looking strange in task manager Pin
Dan Wulff1-Apr-15 11:16
Dan Wulff1-Apr-15 11:16 
SuggestionRe: c# file I/O looking strange in task manager Pin
Richard Deeming1-Apr-15 11:22
mveRichard Deeming1-Apr-15 11:22 
GeneralRe: c# file I/O looking strange in task manager Pin
Dan Wulff1-Apr-15 11:46
Dan Wulff1-Apr-15 11:46 
AnswerRe: c# file I/O looking strange in task manager Pin
Brisingr Aerowing1-Apr-15 11:23
professionalBrisingr Aerowing1-Apr-15 11:23 
GeneralRe: c# file I/O looking strange in task manager Pin
Dan Wulff1-Apr-15 11:44
Dan Wulff1-Apr-15 11:44 
AnswerRe: c# file I/O looking strange in task manager PinPopular
Richard MacCutchan1-Apr-15 21:15
mveRichard MacCutchan1-Apr-15 21:15 
GeneralRe: c# file I/O looking strange in task manager Pin
Dan Wulff2-Apr-15 10:31
Dan Wulff2-Apr-15 10:31 
AnswerRe: c# file I/O looking strange in task manager Pin
Gerry Schmitz1-Apr-15 21:31
mveGerry Schmitz1-Apr-15 21:31 
GeneralRe: c# file I/O looking strange in task manager Pin
Dan Wulff2-Apr-15 10:34
Dan Wulff2-Apr-15 10:34 
QuestionCreate a Developper Pin
Member 83675021-Apr-15 10:42
Member 83675021-Apr-15 10:42 
AnswerRe: Create a Developper Pin
Dave Kreskowiak1-Apr-15 10:57
mveDave Kreskowiak1-Apr-15 10:57 
GeneralRe: Create a Developper Pin
Member 83675021-Apr-15 11:26
Member 83675021-Apr-15 11:26 
GeneralRe: Create a Developper Pin
PIEBALDconsult1-Apr-15 11:00
mvePIEBALDconsult1-Apr-15 11:00 
QuestionImplementing signalR Asynchronous calls for web service calls with 2 minutes timeout Pin
Member 105259811-Apr-15 8:29
professionalMember 105259811-Apr-15 8:29 

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.