|
-
October 11th, 2012, 11:44 PM
#20
Re: How To Handle An Open Document
Woo Hoo, progress!  
I added the OnUpdate() to the View class and now it executes. As the program starts it passes through the OnUpdate() function twice. Then when I load the file and use GetWindowText() I can see the file data. Major progress, although it may seem trivial to others.
I added a Doc object and did a SetDocumentText(<string data>) and it is now resident in my Doc class. From there I should be able to do the manipulation I want. Now, to get the Doc class to send it back to the View I will need to make a call from the View to Doc.GetDocumentText() and the have the view SetWindowText(<my new data>). Is this correct?
The only thing I am not sure of is how to force the View class to call the Doc class to get the updated document data. Guess I could set up a Message, send it and have the View class respond to the message.
Does this sound like a reasonable plan? I know how to send/receive AFX_Msgs. Or, is there a better way?
Thanks again!
John
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|