473,654 Members | 3,076 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Managed for all New Apps?

For all new desktop apps is managed/CLR recommended? I.e. Native MFC/Win32
not recommended in general for new desktop apps? Speaking in general, not
referring to exceptions (e.g. drivers)
--
Greg McPherran
www.McPherran.com
Feb 28 '06 #1
12 1525
"Greg" <gm@mcpherran.c om> wrote in message
news:BC******** *************** ***********@mic rosoft.com...
For all new desktop apps is managed/CLR recommended?
Recommended for whom? On what platforms? Using what set of assumptions.

If the .Net platform provides everything one needs, if the skills of those
tasked with developing the new applications coincide with what is required,
if all of the target machines have the platform installed, if it provides
all of the performance necessary, it seems it would make sense to use it.
I.e. Native MFC/Win32 not recommended in general for
new desktop apps? Speaking in general, not
referring to exceptions (e.g. drivers)


I think that the world is far too complicated for this to be a binary
proposition - drivers C, applications C++/CLI.

Regards,
Will


Feb 28 '06 #2
> If the .Net platform provides everything one needs
Even if it doesn't. with C++ you can also use native libraries as needed so
this has little/no impact on the decision.
if the skills of those tasked with developing the new applications coincide with what is required If .NET is considered the new recommendation (which is what I am originally
asking), what company is going to use an outdated old technology just because
people may need to come up to speed? Again, this has little/no impact.
if it provides all of the performance necessary Again with C++ can use native as needed so again this is a NOP.
if all of the target machines have the platform installed Again, so a company is going to develop an app based on an outdated
technology instead of installing the freely available Framework!! The
framework can even be deployed with the install and auto-detect on install.
Again a NOP.

So, I'll repeat my original question. Is .NET recommended in general for new
desktop applications instead of MFC etc.?
--
Greg McPherran
www.McPherran.com
"William DePalo [MVP VC++]" wrote:
"Greg" <gm@mcpherran.c om> wrote in message
news:BC******** *************** ***********@mic rosoft.com...
For all new desktop apps is managed/CLR recommended?


Recommended for whom? On what platforms? Using what set of assumptions.

If the .Net platform provides everything one needs, if the skills of those
tasked with developing the new applications coincide with what is required,
if all of the target machines have the platform installed, if it provides
all of the performance necessary, it seems it would make sense to use it.
I.e. Native MFC/Win32 not recommended in general for
new desktop apps? Speaking in general, not
referring to exceptions (e.g. drivers)


I think that the world is far too complicated for this to be a binary
proposition - drivers C, applications C++/CLI.

Regards,
Will


Feb 28 '06 #3
Greg wrote:
So, I'll repeat my original question. Is .NET recommended in general
for new desktop applications instead of MFC etc.?


Recommended by whom? I'm sure the C# team would recommend that. I'm not so
sure about the C++ team.

Seriously though, WinForms 2.0 alleviates many of the shortcomings of 1.x.
We're developing an end-user GUI application with Winforms and have no
significant performance issues that can be traced to the CLR. For many
apps, it's good enough. MFC is still better in terms of what you can
ultimately do and the performance you'll get, but most apps don't need to be
the very fastest or to have pixel by pixel control of their GUI appearance.

For some desktop apps, I'd go .NET, for others, I'd still go MFC (or WTL).

-cd
Feb 28 '06 #4
Greg wrote:
So, I'll repeat my original question. Is .NET recommended in general for new
desktop applications instead of MFC etc.?


Depends on the problem space. To create a quick UI to view data in a
local or remote database server, I'd recommend .net. Web services, yes.
For a video driver to output complex graphics in a video game or CAD
application, I'd go native C++/Win32/MFC.

But then again, this is in very general terms. As was posted by the
previous person, it also depends on the team or individual. If your
already highly productive with C++/Win32/MFC, then do that route. If
not, try .net, or even better, with C++/CLI, you can do the best of
both. :-)

-Don Kim
Feb 28 '06 #5
"Don Kim" wrote:
For a video driver to output complex graphics in a video game or CAD
application, I'd go native C++/Win32/MFC.
"Carl Daniel" wrote: MFC is still better in terms of what you can ultimately do and the performance
you'll get, but most apps don't need to be the very fastest or to have pixel by
pixel control of their GUI appearance.


http://msdn.microsoft.com/library/de.../directx9m.asp

The above link states that using managed DirectX improves perfomance because
it bypasses the COM layer.

Feb 28 '06 #6
"Greg" <gm@mcpherran.c om> wrote in message
news:FB******** *************** ***********@mic rosoft.com...
If the .Net platform provides everything one needs Even if it doesn't. with C++ you can also use native libraries as needed
so
this has little/no impact on the decision.


Huh? You mean if your application was divided, with say, 95% of it native
and 5% .Net that that that would have little impact on your decision? If so,
then we are talking more about religion than technology.
if the skills of those tasked with developing the new applications
coincide with what is required

If .NET is considered the new recommendation (which is what I am
originally
asking), what company is going to use an outdated old technology just
because
people may need to come up to speed? Again, this has little/no impact.


Well, for technologies which succeed it is a matter of when to take the
plunge. As I see it, with Windows the tipping point came with the
introduction of version 3.1. We are only a couple of months past the
introduction of version 2 of the framework. Is now the right time? It
doesn't seem to me to be a foregone conclusion in every instance.
if it provides all of the performance necessary

Again with C++ can use native as needed so again this is a NOP.


Not so. The transitions have a measurable cost.
if all of the target machines have the platform installed

Again, so a company is going to develop an app based on an outdated
technology instead of installing the freely available Framework!! The
framework can even be deployed with the install and auto-detect on
install.
Again a NOP.


Nope. It still depends. In a corporate environment desktops tend to be
managed. There, tens of megabytes do not get installed without _lots_ of
advance planning. And most users don't have the administrative privilege to
run dotnetfx.exe in any case.
I'll repeat my original question. Is .NET recommended in general for new
desktop applications instead of MFC etc.?


If you are waiting for a simplistic answer to a complicated issue you will
be waiting long after this thread dies.

Regards,
Will
Feb 28 '06 #7
"Greg" <gm@mcpherran.c om> wrote in message
news:51******** *************** ***********@mic rosoft.com...
http://msdn.microsoft.com/library/de.../directx9m.asp

The above link states that using managed DirectX improves perfomance
because
it bypasses the COM layer.


Improves performance over what?

Surely it improves performance over a solution built with .Net that uses
COM-callable wrappers or IJW to access the native API. But does it improve
performance over the native version? I think not.

In this article

http://msdn.microsoft.com/msdnmag/is.../07/DirectX90/

which introduced Managed DirectX a couple of years ago there is this:

<quote>
Managed Direct3D, part of the DirectX Graphics component of DirectX 9.0,
provides a great opportunity for developers targeting the .NET Framework to
add 3D capability to their applications. Not only is managed Direct3D nearly
as efficient as its unmanaged counterpart, but when used in conjunction with
the high-level shading language, it provides a great future for
high-performance RAD game development.
</quote>

And at this link

http://msdn.microsoft.com/msdnmag/is...08/EndBracket/

you'll find this:

<quote>
It seems that at least twice a week, I am asked about poor performance in
Managed DirectX®. This frequency is actually a big improvement over the 5-10
times a week I was asked a few years ago when the technology first came out.
</quote>

The author goes on to explain that the poor performance has more to do with
the way in which the managed libraries were used than with inherent
slowness. And that reinforces the notion that matching a technology to the
skill set of the developers is important. Native DirectX has been around
longer and there is much more collective wisdom about it for others to read
than the newer technology.

Regards,
Will




Feb 28 '06 #8
Hi Will and Thank You,
"Greg" <gm@mcpherran.c om> wrote in message
news:FB******** *************** ***********@mic rosoft.com...
If the .Net platform provides everything one needs Even if it doesn't. with C++ you can also use native libraries as needed
so
this has little/no impact on the decision.


You mean if your application was divided, with say, 95% of it native
and 5% .Net that that that would have little impact on your decision?

Is it recommended that an app be 95% native?
if the skills of those tasked with developing the new applications
coincide with what is required

If .NET is considered the new recommendation (which is what I am
originally
asking), what company is going to use an outdated old technology just
because
people may need to come up to speed? Again, this has little/no impact.


Well, for technologies which succeed it is a matter of when to take the
plunge. As I see it, with Windows the tipping point came with the
introduction of version 3.1. We are only a couple of months past the
introduction of version 2 of the framework. Is now the right time? It
doesn't seem to me to be a foregone conclusion in every instance.

So this is a definite maybe :-)
if it provides all of the performance necessary

Again with C++ can use native as needed so again this is a NOP.

Not so. The transitions have a measurable cost.

No problem if your intelligent about it and minimize transitions i.e. not
chatty. Could still do a hefty recursive math algorithm in native that takes
5 seconds (FFT for example) whereas the interop could be a negligible 1ms or
less of the 5 seconds.
if all of the target machines have the platform installed

Again, so a company is going to develop an app based on an outdated
technology instead of installing the freely available Framework!! The
framework can even be deployed with the install and auto-detect on
install.

Nope. It still depends. In a corporate environment desktops tend to be
managed. There, tens of megabytes do not get installed without _lots_ of
advance planning. And most users don't have the administrative privilege to
run dotnetfx.exe in any case.

No pun intended on the "managed"? :-)
If the company strategy calls for .NET, then IT should accommodate. If a
CEO/CTO lets IT dictate product development strategy, good luck to that
company staying in business.
If you are waiting for a simplistic answer to a complicated issue you will
be waiting long after this thread dies.

That's why I emphasize "in general". In general, is .NET Framework
recommended for new apps as opposed to MFC etc.? I don't get the impression
that Microsoft is promoting .NET for web apps only but that .NET is promoted
for desktop apps as well.

Feb 28 '06 #9
"William DePalo [MVP VC++]" wrote:
Improves performance over what?

Good point.

However, in this video the MS engineer responsible for Managed DirectX
states that the performance of Managed DirectX is only about 2% less than
native DirectX and indicates that the productivity benefits are significant.

http://msdn.microsoft.com/theshow/ep...7/manifest.xml

Feb 28 '06 #10

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

Similar topics

2
276
by: Lars Grøtteland | last post by:
Hello! Could anyone help me please. I tried the following - I created an application in .NET 2003. The project is a MFC Application a CDialog. I ran the application fine. I changed the properties for the app - so I should use Managed Code (Use Managed Extensions = YES). It still ran fine. I should now be able to add new things like Windows Forms. Am I right? You see I tried to add a Windows Form(:NET) item in my app, but when I tried...
0
1293
by: Nick | last post by:
Replying to x-post "Nick" <someone@somewhere.com> wrote in message news:ehLJlC52EHA.1564@TK2MSFTNGP09.phx.gbl... > Hi all, > > Using the .NET fx configuration utility, mscorcfg is it possible to > completely lock down a client computer and ensure that only our (software > publisher) managed and unmanaged applications can run on it? >
30
2818
by: Alper AKCAYOZ | last post by:
Hello Esteemed Developers and Experts, I have been using Microsoft Visual C++ .NET for 1 year. During this time, I have searhed some topics over internets. Most of the topics about .NET is related to C# and Visual Basic .NET. There are less documents about Visual C++ .NET or Managed C++. I wonder the reasons of below questions: 1) Is C# more powerful than Managed C++ and Visual C++ .NET? 2) Is Microsoft intending to support C# and...
1
1121
by: Ricardo | last post by:
Is there much diference in the time a unmanaged code and a managed code spend to run the same process? I'm learning directx and thinking of the performance problem of using it with managed code... thx...
0
886
by: Dan | last post by:
I'm trying to create and display a user control written in C# in one of our legecy C++ apps. Everything compiles and links fine and the managed control is being created but there's no sign of it in the window. That is, I get no run-time errors. I created test apps to bypass the complexities of the real classes I have to deal with. When I had no luck using the managed class directly through the gcroot template I added the CWnd wrapper...
12
1622
by: doug | last post by:
I understand the basics of what managed code offers and that you open yourself up to security issues if you allow unmanaged code. We already have a decent amount of VB6 code to include COM DLLs. If we put wrappers around some of our code or leave some "asis" what makes our existing production code 'evil' just because it is now considered 'unmanaged'? It may seem like a simple niave question, but the definitions for managed and...
0
1284
by: MC-Advantica | last post by:
I have built a managed wrapper class and assembly that expose much functionality available in unmanaged legacy DLLs. I can write VB apps that interface with the managed assembly, and the managed assembly makes calls to the legacy dlls. All seems to work fine when the assembly is a private assembly. When I go through the process of strong naming the assembly and placing it into the GAC, none of my VB apps will initialize. I have gone to...
4
2222
by: =?Utf-8?B?dmlwZXJ4MTk2Nw==?= | last post by:
We are having an issue with an application we are developing. We have a Legacy COM DLL in C++ that we have converted to Visual Studio 2008. This COM DLL has methods that are calling Managed C# assemblies as pass thru to support legacy applications in an effort to move our code to the new Code base. Our COM Object can be instantiated on Windows XP in any COM supported environment using Visual C++, Visual Basic, ASP.NET or ASP and works...
66
3322
by: John | last post by:
Hi What are the advantages actually achieved of managed code? I am not talking of theory but in reality. Thanks Regards
0
8375
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
8815
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8707
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
8482
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
7306
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6161
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4149
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4294
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1593
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.