简体   繁体   中英

Is it possible to target a specific .NET Framework Version or Profile using command line without a VS solution or project file?

I am trying to target the full .NET 4.0, as described here, because the default seems to target the client profile:

http://blogs.msdn.com/b/jgoldb/archive/2009/10/19/what-s-new-in-net-framework-4-client-profile-beta-2.aspx

I also see instructions here:

http://msdn.microsoft.com/en-us/library/bb398202.aspx

But I am wondering whether there's a flag or combination of flags I can pass to csc.exe to target the full framework without using Visual Studio. More specific, I'd like to avoid solutions that require creating a solution or project file.

As far as I know, target framework just specifies where to look the types in and what types to look for. So, as long as you use only the types defined in the .NET version you want, it will be compatible with that version's runtime compiled without any additional options.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM