Appendix B. Downloading and Compiling the SRS Source Code

All the source code and supporting data files for the key example programs in this book are available for download from the Apress web site, www.apress.com/book/sourcecode, as a single file named 9781430210887.zip. To download the file, select the title of this book from the list, click the Submit button, and then click the Download Source Code File link. When downloaded and unzipped, this will create the directory structure shown in Figure B-1. At the top level of the file structure is a folder named Code, in which there are folders that correspond to the chapters of this book that have sample code.

Figure B.1. The source code directory structure

For Chapters 1416, the SRS-specific files will be located in a subdirectory called SRS—for example, xxxChapter14SRS. For Chapters 14 and 16, small example programs unrelated to the SRS—for example, the TestForm examples from Chapter 16—will be located in the Chapter 14 and Chapter 16 "parent" subdirectories, respectively.

To compile the SRS code for a particular chapter, change your default working directory to the appropriate xxxChapternnSRS subdirectory (for example, xxxChapter14SRS) and enter the appropriate compile command, which in many cases will simply be the following:

csc /out:SRS.exe *.cs

In other situations, the compilation command needs to be a bit more complicated (for selected code in Chapters 15 and 16, for example), so you'll be given specific instructions at that point in the chapter text.

Following the procedure that was outlined in Chapter 13, if the SRS source code for a given chapter has been compiled into a file named SRS.exe, the SRS application can be run by typing the command-prompt command:

SRS

To compile and run individual example files such as TestForm.cs, change your default working directory to the appropriate chapter subdirectory (xxx/Chapter14 or xxx/Chapter16), and type the following:

csc programName.cs
				programName

to compile and run the program of interest. For example:

csc TestForm.cs
TestForm

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset