If I develop a 64 bit webpart DLL does it work with SharePoint 2007 32 bit?
ok... Is it do we need to do any settings to achieve that????
sahil
2010-01-11 06:11:35
Nope, you can't force 64-bit dll in a 32-bit process. I would rather focus on ArjanP's question of why is your web-part 64-bit only? Can you install a 32-bit version of it?
Franci Penov
2010-01-11 18:04:01
i want to make a generic webpart so that it should work with all machines..
sahil
2010-01-12 05:35:03
Then you have to build two versions of your web part - one 32-bit and one 64-bit. Even if there was a magic setting that would allow 32-bit SharePoint to load 64-bit webparts, I would assume that it's under the control of the SP admin, not yours.
Franci Penov
2010-01-12 06:35:40
+1
A:
By default a .NET assembly will target "Any CPU" (see Build > Configuration manager in Visual Studio).
This means that the Intermediate Language (IL) code produced will be Just In Time (JIT) compiled into 32bit code when running on a 32 bit OS and 64 bit code when running on a 64 bit OS.
Unless you are doing something very funky (which is unlikely in a SharePoint web part) then you should leave it as "Any CPU" and simply not worry about it any more - it will just automagically work.
Ryan
2010-05-04 16:20:39