views:

22

answers:

3

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

+1  A: 

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.

codekaizen
+1  A: 

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.

Billy Hamlin
+1  A: 

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.

Hans Passant