Results 1 to 2 of 2

Thread: GetActiveDocument VC++

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Apr 2001
    Posts
    843

    GetActiveDocument VC++

    Hello everybody...

    I just learned that the GetActiveDocument function returns the active document on an MDI app in VC++.

    This is my code

    CUnoDoc* pDoc=(CUnoDoc*)GetActiveDocument();
    MessageBox(pDoc->GetTitle());

    When it gets to the part where it gets the title it sends me an assetion error. Like if no document would exist!

    Can anyone help me?

    Thank you
    "The difference between mad and genius is the success"

  2. #2

    Thread Starter
    Fanatic Member
    Join Date
    Apr 2001
    Posts
    843
    Thanks CornedBee... the function works.
    "The difference between mad and genius is the success"

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