September 20, 2005
MarkBernstein.org
 
Follow me on Twitter

MFC?

I've got a recurring headache with MFC and Windows.

I want a testable document class, which means a document class that can be instantiated independently of the whole view hierarchy. So, while normally a TinderboxDoc gets made by the CDocTemplate along with a frame window, sometimes I was to be able to instantiate a TinderboxBox all by itself. Fine, so far.

Now, though, I'd like to take my TinderboxDoc and say, "make yourself a frame window, please." What's the idiomatic way to do this with MFC? Surely it's an FAQ, but our current solution can't be right. Got ideas? Drop me a note. Could easily turn into a nice little consulting gig.