Application error message when application runs solo

My application works fine as long as I have Borland C++ 4.52 loaded,
even when I run it from the Program Manager. But if I try to run it
without the Borland shell loaded, there is an application error when I
select one of the menus of my application.

Any help would be much appreciated.