Diplay a modal FormView by DLL for VB 4

I am writting a DLL for VB4 with MFC 4.2, to display a form like window for VB. I use MFC full server as the base and run into poblem of the window display is always under the VB form that starts it. I got around by using SetForegroundWindow(), then I am not able to make it Modal (like a Dialog box), I tried RunModalLoop, it works, but when it ends it throws an error to VB, the other option I have was BeginModalState(), but there is very little example of how to use it, and the form disable itself. Any body know how to make the form modal?
hshliangAsked:
Who is Participating?
 
dr_funfrockConnect With a Mentor Commented:
hshliang,

   The best answer is create an activex control. When the contorl is initiated create a dialog box to display your 'form' information and controls.

Doc
0
 
piano_boxerCommented:
What kind of error do you get?
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.