ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Ok, I have a C++ Program (windows) and I want to do it GUI, I have all the code (alot of code) and I want to use Visual C++ to make it GUI. Is it difficult to do this or should I just change my code to Visual Basic. Thanks.
Just compiling your code with VC++ isn't going to automatically give it a GUI. You don't say what version of VC++ you are using, but either way, you'll have to write your GUI portion of the code, and somehow plug in the existing code into it. The difficulty level of that really depends on how your current app is coded, and how you want to change it.
If you are using VC++ .Net 2003, there is pretty good support for building GUIs using the .Net framework's Windowing forms... If you are using an older version of VC++ (6.0, or an earlier .Net version), then you will probably find it a bit easier to use MFC. Or, you could just go directly to the Win32 API...
I wouldn't go with VB, though. Especially if it is VB 6...
I have VC++ 6.0, I am doing it in VB because it was much easier, if you could tell me why not to do it in VB I would appreciate it and maybe change it to VC++.
Maybe I'm biased, but I have had to use VB 6 at work, and have also used VC++ since version 4.0. Here are some reasons I despise VB 6:
It tries to be object-oriented, but doesn't support basic object-oriented concepts like inheritence, virtual functions etc.
It uses an apartment threaded model, which basically means only one thread of execution can gain access to your VB functions at any one time.
Trying to use the Win32 API functions directly to get a free-threaded models can be done, but is notoriously difficult and easily crashes.
Trying to use the Win32 API and other similar C libraries requires you to import each and every function you want to use directly from the DLL. With VC++ you usually have headers and libraries that make it much easier to use.
If you have a C++ class library you cannot use it directly in VB.
It is very Microsoft specific. Some things for VC++ such as MFC and certain keywords are also Microsoft specific, but it is still C++, so you can take the C++ concepts you learn and apply it to other platforms.
This being mainly a Linux oriented forum, I don't think you will find too many people sympathetic towards VB...
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.