Click here to Skip to main content
15,915,788 members
Home / Discussions / C#
   

C#

 
GeneralRe: How to keep track of background threads? Pin
N a v a n e e t h27-May-08 3:18
N a v a n e e t h27-May-08 3:18 
GeneralRe: How to keep track of background threads? Pin
ptr2void27-May-08 3:24
ptr2void27-May-08 3:24 
GeneralRe: How to keep track of background threads? Pin
N a v a n e e t h27-May-08 3:41
N a v a n e e t h27-May-08 3:41 
GeneralRe: How to keep track of background threads? Pin
ptr2void27-May-08 3:52
ptr2void27-May-08 3:52 
GeneralRe: How to keep track of background threads? Pin
supercat912-Jul-08 12:21
supercat912-Jul-08 12:21 
QuestionWord Plug-in eventhandlers stops working... Pin
Anders Molin27-May-08 3:00
professionalAnders Molin27-May-08 3:00 
QuestionSetting values for anonymous types Pin
Yoyosch27-May-08 2:34
Yoyosch27-May-08 2:34 
AnswerRe: Setting values for anonymous types Pin
Colin Angus Mackay27-May-08 3:13
Colin Angus Mackay27-May-08 3:13 
Yoyosch wrote:
How to assign a value for the specific field of that variable?


You can't.

When you create an anonymous type the following code is generated:
private static void Main(string[] args)
{
    var a;
    a = new <>f__AnonymousType0<int, int>(1, 2);
    return;
}


The special class <>f_AnonymousType0 looks like this:

[CompilerGenerated, DebuggerDisplay(@"\{ i = {i}, j = {j} }", Type="<Anonymous Type>")]
internal sealed class <>f__AnonymousType0<<i>j__TPar, <j>j__TPar>
{
    // Fields
    [DebuggerBrowsable(0)]
    private readonly <i>j__TPar <i>i__Field;
    [DebuggerBrowsable(0)]
    private readonly <j>j__TPar <j>i__Field;

    // Methods
    [DebuggerHidden]
    public <>f__AnonymousType0(<i>j__TPar i, <j>j__TPar j);
    [DebuggerHidden]
    public override bool Equals(object value);
    [DebuggerHidden]
    public override int GetHashCode();
    [DebuggerHidden]
    public override string ToString();

    // Properties
    public <i>j__TPar i { get; }
    public <j>j__TPar j { get; }
}


As you can see, there are no setters on any of those properties.


QuestionHow to block popups in broswer component? Pin
asma_panjabi27-May-08 2:14
asma_panjabi27-May-08 2:14 
AnswerRe: How to block popups in broswer component? Pin
buchstaben27-May-08 5:22
buchstaben27-May-08 5:22 
GeneralRe: How to block popups in broswer component? Pin
asma_panjabi27-May-08 22:38
asma_panjabi27-May-08 22:38 
AnswerRe: How to block popups in broswer component? Pin
asma_panjabi29-May-08 0:38
asma_panjabi29-May-08 0:38 
QuestionDependency injection - Static properties Pin
N a v a n e e t h27-May-08 1:59
N a v a n e e t h27-May-08 1:59 
AnswerRe: Dependency injection - Static properties Pin
Pete O'Hanlon27-May-08 2:08
mvePete O'Hanlon27-May-08 2:08 
GeneralRe: Dependency injection - Static properties Pin
N a v a n e e t h27-May-08 2:11
N a v a n e e t h27-May-08 2:11 
GeneralRe: Dependency injection - Static properties Pin
Pete O'Hanlon27-May-08 3:00
mvePete O'Hanlon27-May-08 3:00 
GeneralRe: Dependency injection - Static properties Pin
N a v a n e e t h27-May-08 3:07
N a v a n e e t h27-May-08 3:07 
QuestionRe: Dependency injection - Static properties Pin
mr_lasseter27-May-08 6:08
mr_lasseter27-May-08 6:08 
AnswerRe: Dependency injection - Static properties Pin
N a v a n e e t h27-May-08 6:13
N a v a n e e t h27-May-08 6:13 
GeneralRe: Dependency injection - Static properties Pin
mr_lasseter27-May-08 6:30
mr_lasseter27-May-08 6:30 
GeneralRe: Dependency injection - Static properties Pin
N a v a n e e t h27-May-08 6:38
N a v a n e e t h27-May-08 6:38 
Questionhow to a a object array parameter of a WebService/WebMethod to accept DBNull ? Pin
AlbertEiki27-May-08 1:47
AlbertEiki27-May-08 1:47 
AnswerRe: how to a a object array parameter of a WebService/WebMethod to accept DBNull ? Pin
leppie27-May-08 1:52
leppie27-May-08 1:52 
QuestionC# Browser Back Button recognition. Pin
imnotso#27-May-08 0:35
imnotso#27-May-08 0:35 
AnswerRe: C# Browser Back Button recognition. Pin
leppie27-May-08 1:35
leppie27-May-08 1:35 

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.