Create a a conditional compilation symbol in the properties page of your project that encloses the problematic file, for example
NET40
then, in code write
#if NET40
splash.Show(false, true);
#else
splash.Show(true);
#endif
You could also create two different Configuration Settings with the Configuration Manager.
In the first one you don't have the NET40 defined and you could call it CompileFor35 while in the other one you define the compilation symbol and call it CompileFor40.
At this point, to switch from one version to the other one, you could simply recall the appropriate configuration setting from the menu BUILD->Configuration Manager
You could read about the steps required in a bit more detail in this answer