Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > .NET General

Vista - Calling 32 bit COM+ from DotNet App on a 64 bit OS

Reply
 
Old 10-23-2008   #1 (permalink)
Ashish P K


 
 

Calling 32 bit COM+ from DotNet App on a 64 bit OS

I have a .Net Application(64 bit) calling a 32 bit COM+. What is the best
way to achieve this?

Basically I have got a webpart dll, which is compiled for any CPU and IIS
running on 64 bit. All the webparts works fine but the webpart which are
accessing legacy COM+ methods fails to get loaded.

To test this further I created a small DotNet Sample App which loads
COM+method. If the Sample app is comiled for 32 everything works on 64 bit
OS.
But I can't go with this because my webparts.dll gets loaded from IIS which
is running in 64 bit. (Running IIS is 32 mode is not an option)

Tried using corflags.exe to change the interop dll to 32 mode that also
din't help.

Any suggestions would be appreciated.


Thanks,
Ashish



My System SpecsSystem Spec
Old 10-23-2008   #2 (permalink)
Jeroen Mostert


 
 

Re: Calling 32 bit COM+ from DotNet App on a 64 bit OS

Ashish P K wrote:
Quote:

> I have a .Net Application(64 bit) calling a 32 bit COM+. What is the best
> way to achieve this?
>
> Basically I have got a webpart dll, which is compiled for any CPU and IIS
> running on 64 bit. All the webparts works fine but the webpart which are
> accessing legacy COM+ methods fails to get loaded.
>
> To test this further I created a small DotNet Sample App which loads
> COM+method. If the Sample app is comiled for 32 everything works on 64 bit
> OS.
> But I can't go with this because my webparts.dll gets loaded from IIS which
> is running in 64 bit. (Running IIS is 32 mode is not an option)
>
> Tried using corflags.exe to change the interop dll to 32 mode that also
> din't help.
>
Your can host the component in a 32-bit executable (using corflags to force
it so) and use some means of interprocess communication (other than COM,
obviously) to shuttle requests back and forth. Look at .NET remoting or WCF
for this.

You will not be able to devise a solution that doesn't use a separate
hosting executable -- the dividing line between 32-bit and 64-bit is fairly
absolute.

--
J.
My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
Which version of dotnet? .NET General
Beginner - which is best dotnet.VB or dotnet.VC? .NET General
Dotnet 2.0 .NET General
Re: dotNet and DTS problem .NET General
interesting "issue" or "bug" with psobjects when calling DOTNET framework stuff PowerShell


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46