HELP! WIN32 API Error on Manual Repaint

I am calling the windows API  BitBlt to manually paint an image on the
backgoround of a MDI parent in a D3 program.  This appears to work fine
(visually) but when I try to open an MDI child I get a WIN32 API Error
saying  "A WIN32 API function failed".  In the IDE, I earlier got an API
Error message number that translated into "RROR_File_already_open" when I
looked it up.

The program use to work without error, but I have made many changes since
then.  I have a added a coolbar and suspect the problem may lie there?

Any help would be GREATLY appreciated.  Thanks in Advance, and please copy
me on any reply.
Regards,
Scott St.Cyr
Cyrious Software
M. Scott St.Cyr
Cyrious Software, Inc.
//***************************************************************//