Quick Tip: Windows Phone 7 Preprocessor DirectiveSubmitted by smartyP on Mon, 08/02/2010 - 19:01
If you're sharing common code between Windows Phone 7 and other platforms in either Silverlight or XNA, then you may run into a need to fork some code based on the platform. This is normally done with a preprocessor directive, which for Windows Phone 7 is WINDOWS_PHONE.
#if WINDOWS_PHONE // TODO:: WP7 specific code #endif
It took me a while to find this, so for future reference know that you can always find this in the project's properties panel: