开发者

dll built with visual studio 2010 / windows 7 => usable on Windows 6?

Question from a Linux/Mac developer: I have compiled a 32-bit .dll (release flavor) under Windows 7 using Visual Studio 2010. Should this .dll be usable under all flavors of Windows 6 (a.k.a. Vista, if I'm not mistaken)?

Many开发者_开发百科 thanks and RTFMs appreciated,

John Clements


In general: yes.

All current versions of the .Net framework run on both Vista and Win7.

Note that if you make calls into the native platform, either directly or via the Windows API Code Pack, you could have portability problems if you use functions available only in Win7. But for just straight .Net development, you should have no issue in running on any supported version of Windows.


Yes, the dll format didn't change for Windows 7. Only thing to remember is that if it's a .Net dll, the target system must have the proper .Net installed or the appropriate C/C++ runtime.


You're supposed to #define the _WIN32_WINNT macro to tell what version of Windows you want to support. The default in the SDK that ships with VS2010 is 0x600 which avoids you ever linking to an API function that is not available in Vista. So, yes, you're probably good to go.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜