Hello, I'm having an issue with the syntax for DLL function imports in VS C++ 2010. The following lines are in the .NET 2003 format:
Code:
[DllImport("gxsw.dll", EntryPoint="Gx6315Initialize", CharSet=CharSet::Ansi)]
extern void __cdecl Gx6315Initialize(int slot, int __gc* pHandle, short __gc* pnStatus);
To convert it to .NET 2010 syntax, I came up with this:
Code:
[DllImport("gxsw.dll", EntryPoint="Gx6315Initialize", CharSet=CharSet::Ansi)]
extern void __cdecl Gx6315Initialize(__int16 slot, __int16 __gc* pHandle, __int16 __gc* pnStatus);
Can someone who's adept at the .NET 210 syntax tell me if this is correct? If not, what isn't? This is the first time I'm coding in .NET 2010, and could really use some pointers.