Using .NET 1.1 via interop from .Net 2.0

Discussion in 'Microsoft C# .NET' started by schaf, Jun 9, 2008.

  1. schaf

    schaf Guest

    HI NG!
    I have converted my Project from .NET 1.1 to .NET 2.0.
    In my project I use C++ assemblies via an interop dll.
    When I use the old assemblies (old means the same referenced asseblies
    as I used for the same project in .NET 1.1)

    But if I convert my subproject to .NET 2.0 nad I use this ones, I get
    a InvalidCastException: Specified cast not valid:.

    Convert.ToBoolean(myInteropObject.AdviseEventSink(this));

    Does the convertion of the project to .NET 2.0 change any settings? Or
    is it not permitted to pass a .NET 2.0 object as an EventSink ? But
    why does it work with the old assemblies?

    Do you have hints?

    Thanks
    Regrads
    Marcel
     
    schaf, Jun 9, 2008
    #1
    1. Advertisements

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Similar Threads
  1. bob

    Using Excel Interop

    bob, Oct 1, 2003, in forum: Microsoft C# .NET
    Replies:
    0
    Views:
    286
  2. Bob

    Using Excel Interop

    Bob, Oct 16, 2003, in forum: Microsoft C# .NET
    Replies:
    0
    Views:
    440
  3. Tamir Khason

    Interop without interop

    Tamir Khason, Nov 30, 2003, in forum: Microsoft C# .NET
    Replies:
    11
    Views:
    769
    Alvin Bruney
    Dec 1, 2003
  4. Guest

    Creating a COM interop using VS.NET 2005?

    Guest, Dec 22, 2005, in forum: Microsoft C# .NET
    Replies:
    3
    Views:
    246
    Peter Huang [MSFT]
    Dec 28, 2005
  5. Guest

    Creating a COM interop using VS.NET 2005?

    Guest, Dec 28, 2005, in forum: Microsoft C# .NET
    Replies:
    16
    Views:
    1,711
    Peter Huang [MSFT]
    Jan 6, 2006
  6. Willy Denoyette [MVP]

    Re: Help with accessing .NET 2.0 COM interop libraries via classic ASP

    Willy Denoyette [MVP], Jan 5, 2007, in forum: Microsoft C# .NET
    Replies:
    1
    Views:
    431
    Willy Denoyette [MVP]
    Jan 5, 2007
  7. Arnshea

    modifying a string array via MFC COM Interop

    Arnshea, Nov 28, 2007, in forum: Microsoft C# .NET
    Replies:
    6
    Views:
    318
    Giovanni Dicanio
    Nov 28, 2007
  8. muriwai
    Replies:
    7
    Views:
    5,756
    abecerra
    Oct 27, 2011
Loading...