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.

Properties Sample

This sample shows how properties are an integral part of the C# programming language. It demonstrates how properties are declared and used.

This sample contains the source code for the Properties Tutorial.

Building and Running the Sample Within Visual Studio

To build and run the Properties samples

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

Building and Running the Sample from the Command Line

To build and run the Properties samples

  1. Use the Change Directory command to change to the person directory.
  2. Type the following:
    csc person.cs
    person
    
  3. Use the Change Directory command to change to the shapetest directory.
  4. Type the following:
    csc abstractshape.cs shapes.cs shapetest.cs
    shapetest
    

See Also

Properties Tutorial | Tutorial Samples

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2015 Microsoft