Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. ATL / WTL / STL
  4. unhandle exception(8000ffff) while acceing ocx methods

unhandle exception(8000ffff) while acceing ocx methods

Scheduled Pinned Locked Moved ATL / WTL / STL
helpcomdebugging
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Rajesh match
    wrote on last edited by
    #1

    i am trying to access mehod of ocx but its showing runtime error HRESULT hret; try { CoInitialize(NULL); // init of Com hret = testPtr.CreateInstance(__uuidof(TestOCX)); testPtr->Check(); //Crash here } catch( _com_error &e ) { // Get info from _com_error _bstr_t bstrSource(e.Source()); _bstr_t bstrDescription(e.Description()); TRACE( "\tCode = %08lx\n", e.Error()); TRACE( "\tCode meaning = %s\n", e.ErrorMessage()); TRACE( "\tSource = %s\n", (LPCTSTR) bstrSource); TRACE( "\tDescription = %s\n", (LPCTSTR) bstrDescription); } catch(...) { TRACE( "*** Unhandled Exception ***" ); } can anybody help me for the same thanx regards Rajesh

    M J 2 Replies Last reply
    0
    • R Rajesh match

      i am trying to access mehod of ocx but its showing runtime error HRESULT hret; try { CoInitialize(NULL); // init of Com hret = testPtr.CreateInstance(__uuidof(TestOCX)); testPtr->Check(); //Crash here } catch( _com_error &e ) { // Get info from _com_error _bstr_t bstrSource(e.Source()); _bstr_t bstrDescription(e.Description()); TRACE( "\tCode = %08lx\n", e.Error()); TRACE( "\tCode meaning = %s\n", e.ErrorMessage()); TRACE( "\tSource = %s\n", (LPCTSTR) bstrSource); TRACE( "\tDescription = %s\n", (LPCTSTR) bstrDescription); } catch(...) { TRACE( "*** Unhandled Exception ***" ); } can anybody help me for the same thanx regards Rajesh

      M Offline
      M Offline
      Michael Dunn
      wrote on last edited by
      #2

      What's the return value from CreateInstance()? --Mike-- Visual C++ MVP :cool: LINKS~! Ericahist | 1ClickPicGrabber | NEW~! CP SearchBar v3.0 | C++ Forum FAQ "Linux is good. It can do no wrong. It is open source so must be right. It has penguins. I want to eat your brain."   -- Paul Watson, Linux Zombie

      1 Reply Last reply
      0
      • R Rajesh match

        i am trying to access mehod of ocx but its showing runtime error HRESULT hret; try { CoInitialize(NULL); // init of Com hret = testPtr.CreateInstance(__uuidof(TestOCX)); testPtr->Check(); //Crash here } catch( _com_error &e ) { // Get info from _com_error _bstr_t bstrSource(e.Source()); _bstr_t bstrDescription(e.Description()); TRACE( "\tCode = %08lx\n", e.Error()); TRACE( "\tCode meaning = %s\n", e.ErrorMessage()); TRACE( "\tSource = %s\n", (LPCTSTR) bstrSource); TRACE( "\tDescription = %s\n", (LPCTSTR) bstrDescription); } catch(...) { TRACE( "*** Unhandled Exception ***" ); } can anybody help me for the same thanx regards Rajesh

        J Offline
        J Offline
        JonEngle
        wrote on last edited by
        #3

        Sounds like a bug in the OCX, it might be expecting you to call some initialization function first. 0x8000ffff is E_CATASTROPHIC, which is pretty much a catch-all for "something bad happened". Is this your own ocx? If it is, you should be able to step through it in the debugger. If not, I'd still run it in the debugger and look for first-chance exceptions, that would be a good indication of something wrong in the 'Check' method.

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups