Solved

Create instance of Windows Control Library in MFC View...

Posted on 2004-08-11
4
268 Views
Last Modified: 2008-03-06
Hi,

I have an MFC View that I wish to display a Windows Control Libary on (in my case, a form to take some information)

Is this possible?  I have written a WCL in VB what is a simple form with a button on it, but have no idea how to add it to the View!!!

Any help would be appreciated...

James
0
Comment
Question by:jatkin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 4

Author Comment

by:jatkin
ID: 11817851
Can anybody help me out with this one???  :-(
0
 

Accepted Solution

by:
mrduncanm earned 250 total points
ID: 11878238
first you will need to create a dialog based program... That will remid you a lot of VB.

Or the more MFC way (so you get Doc/View) is to create a SDI app and in the final stages of the app wizard click on the file called C*yourprojname*View and set the base class to CFormView. Then the view will have a dialog resorce that is automagicaly displayed when run.
0
 

Expert Comment

by:mrduncanm
ID: 11878249
oh and then I forget that if you are in the dialog editing mode you may have noticeed a toolbax. right click on that and "Add/Remove items"  from there you should be able to browse for your custom control. This will add a button to that toolbox you click on it and add it to your form and your off.

But then again the more MFC way would be to kick VB to the curb and do it all in MFC. After all it can do *almost* (had to put that in there or someone would complain) anything VB can and usually better.
0
 
LVL 4

Author Comment

by:jatkin
ID: 11878366
CFormView ! ! ! !   That will do nicely!

I agree with the power of C - and program almost 100% in MFC...  It's just that I have existing controls in VB that would take some time to port accross...

Thanks for the help...

James
0

Featured Post

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The following diagram presents a diamond class hierarchy: As depicted, diamond inheritance denotes when two classes (e.g., CDerived1 and CDerived2), separately extending a common base class (e.g., CBase), are sub classed simultaneously by a fourt…
In Easy String Encryption Using CryptoAPI in C++ (http://www.experts-exchange.com/viewArticle.jsp?aid=1193) I described how to encrypt text and recommended that the encrypted text be stored as a series of hexadecimal digits -- because cyphertext may…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question