Inside C#, Third Edition comments and corrections (916207)



The information in this article applies to:

  • Inside C#, Third Edition, ISBN 0-7356-1954-9

SUMMARY

This article contains comments, corrections, and information about known errors relating to the Microsoft Press book Inside C#, Third Edition, 0-7356-1954-9.
The following topics are covered:

  • Page 101: Missing Code

MORE INFORMATION

Page 101 Missing Code

On page 101, change the following code:
class ValRefTest
{
    static void Main(string[] args)
    {
        AnotherClass ref1 = new AnotherClass();
        ref1.ID = 3;
        AnotherClass ref2 = sc.ChangeObject(ref1);
        Console.WriteLine("ref1.ID = {0}, ref2.ID = {1}",
            ref1.ID, ref2.ID);
    }
}
 

To:
class ValRefTest
{
    static void Main(string[] args)
    {
        SomeClass sc = new SomeClass();
        AnotherClass ref1 = new AnotherClass();
        ref1.ID = 3;
        AnotherClass ref2 = sc.ChangeObject(ref1);
        Console.WriteLine("ref1.ID = {0}, ref2.ID = {1}",
            ref1.ID, ref2.ID);
    }
}

Modification Type:MajorLast Reviewed:4/7/2006
Keywords:kbdocfix kbdocerr KB916207 kbAudEndUser