CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Nov 2000
    Posts
    2

    method '~' of object '~' failed

    I get this error inconsistently when calling a method of a successfully instantiated VB COM object (ActiveX DLL) running under MTS.
    Cannot recreate this error consistently.
    Please help.......


  2. #2
    Join Date
    Nov 2000
    Posts
    8

    Re: method '~' of object '~' failed

    This is nasty, ugly awful stuff but here goes...

    You should be using binary compatibility for your component. If you're not, use binary compatibilty. Follow this procedure:

    1) Clear compatibility on your component
    2) Compile your component
    3) Make a copy of the compiled DLL
    4) Use binary compatibilty to the copy you just made
    5) Rebuild the MTS packages (or COM+ applications) and point them at the newly compiled (not copy of...) dll.

    From now on, if you add a new public sub or function or if you change the parameter list or return type of an existing sub or function, you must repeat the steps I outlined above. Keep in mind that VB WILL NOT always tell you that compatibilty is breaking in a way that forces and update of the copy of and the MTS package.

    The error you are seeing is a direct result of changing GUID identifiers for interfaces. I really don't want to write the page or so of explanation of all the details that explain why or how or exactly the reasoning behind the steps. Just trust me because they work.


  3. #3
    Join Date
    Oct 2001
    Location
    Bangalore.INDIA
    Posts
    25

    Re: method '~' of object '~' failed

    Hi,
    This error is related to MTS transactions.
    Check out properties of components and usage of setabort and setcomplete are correct.Verfify that
    and that only.make sure MSDTC service started
    regards



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured