Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.
8 out of 37 rated this helpful - Rate this topic

Delegates Sample

This sample demonstrates the delegate types. It shows how to map delegates to static and instance methods, and how to combine them (multicast).

This sample contains the source code for the Delegates Tutorial.

Building and Running the Sample Within Visual Studio

To build and run the Delegates samples

  1. Open the solution (Delegates.sln).
  2. In Solution Explorer, right-click the Delegates1 project and click Set as StartUp Project.
  3. From the Debug menu, click Start Without Debugging.
  4. Repeat the preceding steps for Delegates2.

Building and Running the Sample from the Command Line

To build and run the Delegates samples

  1. Use the Change Directory command to change to the Delegates1 directory.
  2. Type the following:
    csc bookstore.cs
    bookstore
    
  3. Use the Change Directory command to change to the Delegates2 directory.
  4. Type the following:
    csc compose.cs
    compose
    

See Also

Delegates Tutorial | Tutorial Samples

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.