User Profile

Collapse

Profile Sidebar

Collapse
MiddleTommy
MiddleTommy
Last Activity: Jun 28 '07, 01:19 PM
Joined: May 24 '07
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • MiddleTommy
    replied to C# Object Reference?
    in .NET
    class WrapperObject
    { public TrackedObject obj }

    //now you can do this.
    WrapperObject A = new WrapperObject() ;
    A.obj = new TrackedObject() ;
    WrapperObject B = new WrapperObject() ;

    TrackedObject C = new TrackedObject() ;
    B.obj = C;

    //now A.obj = C
    See more | Go to post

    Leave a comment:


  • MiddleTommy
    replied to C# Object Reference?
    in .NET
    Yeah, I had to put the datarow into the collection

    I suppose for more generic answer
    if you encapsulate a object into another object you can pass the outer object and then change the inner object without loosing the reference?

    or something like that
    See more | Go to post

    Leave a comment:


  • MiddleTommy
    replied to C# Object Reference?
    in .NET
    It would be easy if only C# supported pointers to Reference Types
    See more | Go to post

    Leave a comment:


  • MiddleTommy
    replied to C# Object Reference?
    in .NET
    The real situation is I have a field from a datarow that I put into a collection.
    Then latter I have the collection but not the datarow(but the datarow still exists). I want to set the datarow field to a new value but feel it will only change the collection to the new data and not the orginal datarow field.
    See more | Go to post

    Leave a comment:


  • MiddleTommy
    started a topic C# Object Reference?
    in .NET

    C# Object Reference?

    I know this is possible in C++ with pointers but dont know how to do it in C#.

    Simplified Sample Code and Comments

    //create object A
    object A = new object();

    //create object B
    object B = A;

    //create object C
    object C = new object();

    //I need to change Object A to point to the contents of Object C only using Object B
    See more | Go to post
No activity results to display
Show More
Working...