473,854 Members | 1,527 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Best book for learning MFC/VC 7.1 for developing rich GUI apps ?

Hi,

I am a C/C++ developer of quite a few yesrs, although I am relatively
new to Windows (Unix background). I am about to begin work on a project
that would require me to develop several GUI rich frontend applications.

I would like to hear from developers ou there if there is a book they
would recommend, to help me hit the ground running - i.e. a book that is
NOT an introductory text on programming/C++ but rather one that dives
straight in and shows how to create front ends (possibly widgets etc) -
using the VC IDE, one that covers all I need to know about MFC to start
working on a real world application. A bit of a tall order. But your
recoomendations would be appreciated.

tx

Nov 17 '05 #1
5 2294
>I am a C/C++ developer of quite a few yesrs, although I am relatively
new to Windows (Unix background). I am about to begin work on a project
that would require me to develop several GUI rich frontend applications.

I would like to hear from developers ou there if there is a book they
would recommend, to help me hit the ground running - i.e. a book that is
NOT an introductory text on programming/C++ but rather one that dives
straight in and shows how to create front ends (possibly widgets etc) -
using the VC IDE, one that covers all I need to know about MFC to start
working on a real world application.


Alfonso,

Have a look at Jeff Prosise's Programming Windows with MFC book and
Charles Petzold's Programming Windows for the core SDK aspects of
Windows.

Since you're just starting, many people will ask why you're not
considering starting from the .Net framework - which is where most of
Microsoft's efforts are today. So, have you considered that?

Dave
--
MVP VC++ FAQ: http://www.mvps.org/vcfaq
Nov 17 '05 #2


David Lowndes wrote:
I am a C/C++ developer of quite a few yesrs, although I am relatively
new to Windows (Unix background). I am about to begin work on a project
that would require me to develop several GUI rich frontend applications.

I would like to hear from developers ou there if there is a book they
would recommend, to help me hit the ground running - i.e. a book that is
NOT an introductory text on programming/C++ but rather one that dives
straight in and shows how to create front ends (possibly widgets etc) -
using the VC IDE, one that covers all I need to know about MFC to start
working on a real world application.

Alfonso,

Have a look at Jeff Prosise's Programming Windows with MFC book and
Charles Petzold's Programming Windows for the core SDK aspects of
Windows.

Since you're just starting, many people will ask why you're not
considering starting from the .Net framework - which is where most of
Microsoft's efforts are today. So, have you considered that?

Dave


Hi Dave,

Thanks for the feedback. Good question. My reluctance to move to .NEt is
based on the information (which could be inacuurate) I have gathered so far:

1). It is "not secure" as far as IP is concerned - code is easily
reversible from binaries
2). I HATE the fuss of interoperatabil ity between "managed code" and
"unmanaged code" - pretty much all of my logic is in C/C++ libraries -
really, all I need is to know how to create a GUI frontend for my
libraries - I like .NET GUI capabilities but I don't like the fact that
my binaries can be easily converted to source (even with obfuscation).

3). I don't want to learn a new language - (C#)

If I can be convinced that these objections can be overcome without too
trouble than I may consider using .NET

Nov 17 '05 #3
Alfonso Morra wrote:


David Lowndes wrote:
[...]
Since you're just starting, many people will ask why you're not
considering starting from the .Net framework - which is where most of
Microsoft's efforts are today. So, have you considered that?

Dave

Hi Dave,

Thanks for the feedback. Good question. My reluctance to move to .NEt is
based on the information (which could be inacuurate) I have gathered so
far:

1). It is "not secure" as far as IP is concerned - code is easily
reversible from binaries


Well, IL code can be easier reengineered as native code, since you have
additional information about classes, variable names etc. .
Native code hasn't, except if you have the debug information too ;-).
For that purpose there are obfuscators, e.g. dotfuscator integrated in
the VS Studio IDE. It will obfuscate all variable and class names in the
code so that it's nearly unusable anymore.

But if you use Managed C++, or better C++/CLI, you will normaly mix
native code with .NET code. Such code compiles (normally) to a mixed
binary. If you compile such code you'll get a mixed binary. Mixed native
and managed code. By the way the C++ compiler is the only one which can
compile mixed binaries.

Since you normally call only into the .NET framework or use simple
wrapper classes i think the recompilation problem is neglectable.

2). I HATE the fuss of interoperatabil ity between "managed code" and
"unmanaged code" - pretty much all of my logic is in C/C++ libraries -
really, all I need is to know how to create a GUI frontend for my
libraries - I like .NET GUI capabilities but I don't like the fact that
my binaries can be easily converted to source (even with obfuscation).
See above. Your native source code will still be compiled to native
code. If you are using the GUI as a simple wrapper only i wouldn't care
about recompilation.

3). I don't want to learn a new language - (C#)

You mustn't. It would be C++/CLI (VC++ 8.0) which i strongly recommend
to use instead of the deprecated Managed C++.
It doesn't use that ugly double underscore keywords, since it's an ECMA
standard and scheduled for ISO standardization .
Although it's easier to interoperate with native code now,
C++/CLI code is still managed code and you have to deal with
interoperabilit y issues. There are currently some restrictions mixing
native and managed classes, with which you will have to deal till the
next C++/CLI version, which are currently solved using (existing)
wrapper classes.

Although I like C++/CLI very much, I tend to use C# as language for my
managed GUI's, calling my native code through P/Invoke or COM Interop.
Just because of the compilation times ;-) and I'm much more productive.
Additionally I'm forced to separate GUI code from native (logic) code.
If I can be convinced that these objections can be overcome without too
trouble than I may consider using .NET


I think creating a WinForms GUI is much easier than with MFC. But if you
have to use native code you will have to deal with interoperabilit y
issues and have to decide if the productivity gain of WinForms is worth
the additional interoperabilit y issues.
For me - mostly it is.

If not, perhaps available native C++ RAD GUI frameworks integrating into
the VS IDE might be another valuable alternative for you, e.g. QT4 ?

Only downside:
You might be forced to change the framework in the future since the
future of Windows application with GUI frontends is definitively
managed. And since MFC and WinForms will allow you mixing native and
managed GUI components, i don't know if the alternative native GUI's
will allow it too in the future.

Hard decision to make.

Andre
Nov 17 '05 #4


Andre Kaufmann wrote:
Alfonso Morra wrote:


David Lowndes wrote:
[...]
Since you're just starting, many people will ask why you're not
considering starting from the .Net framework - which is where most of
Microsoft's efforts are today. So, have you considered that?

Dave


Hi Dave,

Thanks for the feedback. Good question. My reluctance to move to .NEt
is based on the information (which could be inacuurate) I have
gathered so far:

1). It is "not secure" as far as IP is concerned - code is easily
reversible from binaries

Well, IL code can be easier reengineered as native code, since you have
additional information about classes, variable names etc. .
Native code hasn't, except if you have the debug information too ;-).
For that purpose there are obfuscators, e.g. dotfuscator integrated in
the VS Studio IDE. It will obfuscate all variable and class names in the
code so that it's nearly unusable anymore.

But if you use Managed C++, or better C++/CLI, you will normaly mix
native code with .NET code. Such code compiles (normally) to a mixed
binary. If you compile such code you'll get a mixed binary. Mixed native
and managed code. By the way the C++ compiler is the only one which can
compile mixed binaries.

Since you normally call only into the .NET framework or use simple
wrapper classes i think the recompilation problem is neglectable.

2). I HATE the fuss of interoperatabil ity between "managed code" and
"unmanaged code" - pretty much all of my logic is in C/C++ libraries -
really, all I need is to know how to create a GUI frontend for my
libraries - I like .NET GUI capabilities but I don't like the fact
that my binaries can be easily converted to source (even with
obfuscation).

See above. Your native source code will still be compiled to native
code. If you are using the GUI as a simple wrapper only i wouldn't care
about recompilation.

3). I don't want to learn a new language - (C#)


You mustn't. It would be C++/CLI (VC++ 8.0) which i strongly recommend
to use instead of the deprecated Managed C++.
It doesn't use that ugly double underscore keywords, since it's an ECMA
standard and scheduled for ISO standardization .
Although it's easier to interoperate with native code now,
C++/CLI code is still managed code and you have to deal with
interoperabilit y issues. There are currently some restrictions mixing
native and managed classes, with which you will have to deal till the
next C++/CLI version, which are currently solved using (existing)
wrapper classes.

Although I like C++/CLI very much, I tend to use C# as language for my
managed GUI's, calling my native code through P/Invoke or COM Interop.
Just because of the compilation times ;-) and I'm much more productive.
Additionally I'm forced to separate GUI code from native (logic) code.
If I can be convinced that these objections can be overcome without too
trouble than I may consider using .NET


I think creating a WinForms GUI is much easier than with MFC. But if you
have to use native code you will have to deal with interoperabilit y
issues and have to decide if the productivity gain of WinForms is worth
the additional interoperabilit y issues.
For me - mostly it is.

If not, perhaps available native C++ RAD GUI frameworks integrating into
the VS IDE might be another valuable alternative for you, e.g. QT4 ?

Only downside:
You might be forced to change the framework in the future since the
future of Windows application with GUI frontends is definitively
managed. And since MFC and WinForms will allow you mixing native and
managed GUI components, i don't know if the alternative native GUI's
will allow it too in the future.

Hard decision to make.

Andre


Thanks for your input Andre. There are many pros and cons on both sides.
However, when all is said and done, the balance (for me) lies with
C++/"old school" MFC. After a little further research, trhis book looks
interesting : "Visual C++ Mfc Programming by Example", I'll borrow it
first, and if its useful, I'll buy it.

Many tks

Nov 17 '05 #5
You'll definitely want to buy "The MFC Answer Book" by Kain. It's one of the
most helpful books I've seen once you've learned the MFC basics.

"Alfonso Morra" <sw***********@ the-ring.com> wrote in message
news:dg******** **@nwrdmz03.dmz .ncs.ea.ibs-infra.bt.com...


Andre Kaufmann wrote:
Alfonso Morra wrote:


David Lowndes wrote:

[...]
Since you're just starting, many people will ask why you're not
considering starting from the .Net framework - which is where most of
Microsoft's efforts are today. So, have you considered that?

Dave

Nov 17 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
343
by: RichG | last post by:
We are building a new developement system specifically for .NET developement. We will bw using VB. and C#. What will be the best OS to install on the new system. What will be the best concidering the developed apps will be ran on everything from Win98 to XP Pro. What will be the best considering building interactive web apps using ASP.NET
11
9295
by: DrUg13 | last post by:
In java, this seems so easy. You need a new object Object test = new Object() gives me exactly what I want. could someone please help me understand the different ways to do the same thing in C++. I find my self sometimes, trying Object app = Object(); Object *app = Object(); Object app = new Object();
136
9495
by: Matt Kruse | last post by:
http://www.JavascriptToolbox.com/bestpractices/ I started writing this up as a guide for some people who were looking for general tips on how to do things the 'right way' with Javascript. Their code was littered with document.all and eval, for example, and I wanted to create a practical list of best practices that they could easily put to use. The above URL is version 1.0 (draft) that resulted. IMO, it is not a replacement for the FAQ,...
26
2586
by: Mark | last post by:
Hello there, Anyone has come a cross a good book in C#? the best books( I hope they are ) that i found so far are: -Programming C#, Third Edition, by Jesse Liberty <--- good, but some discouraging reviews -C# Complete, by Sybex <---- doesn't touch on Interfaces -Murach's C#(.Net Developer), by Joel Murach, Doug Lowe <---- doesn't touch on Threading
4
6709
by: James Thompson | last post by:
I'm sure this question has been asked a hundred times. I did a google search and found some older post and some mixed reviews. I am looking for an updated opinion on which book is the best for learning Visual C++ .NET. A little background, I have been programming C# for the past year and I was a Visual Basic programmer for about 5 years before that. I created a new project in C++ .NET and it is like night and day compared to C#. I was...
4
1424
by: David Pinx | last post by:
Greetings, I will be developing an application that will have two versions, a web application to be deployed at the client side and a windows application. The question is, what would be the best approach for developing these two versions reusing code as much as possible?. Is there a best practice for this type of development? I have read about User Interface Application Block, but I don't know at this
5
1637
by: Rich | last post by:
Hi, I would welcome any opinions on the best approach to developing a web app in order to meet the following requirements: a) the user interface can be easily styled by a graphic designer. b) the content pages can be embedded in other apps if needed (E.g. Outlook). My personal view (being heavily biased to ASP.Net) is to make full use
1
1235
by: Bit Byte | last post by:
I have several years programming experience (C/C++) and have only recently started looking at developing web apps - after playing with PHP for a while, I decided there weren't enough tools etc to get me up and running quickly enough, so I turned to look at ASP.Net ASP.Net looks like it has the development tools that I expect of any serious proposition, but I am confused between the apparent availability of two options: 1. Web...
7
2466
by: simonZ | last post by:
I would like to buy a book with some windows application example in C# net , but all books I have found are only about theory. I would like to have a book, where is explained how to create application from begining to the end. Is there any book with any practical example? Thank you for yours help, Simon
0
9901
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, weíll explore What is ONU, What Is Router, ONU & Routerís main usage, and What is the difference between ONU and Router. Letís take a closer look ! Part I. Meaning of...
0
10675
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10749
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10367
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7079
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5939
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4556
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
4152
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3185
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.