views:

1021

answers:

16

I'm trying to evaluate whether I should make the .NET Framework a requirement for my new Windows app. I believe .NET is the best and most efficient way to write Windows client apps, so it comes down to how painful the next best alternative is. Specifically, I'm trying to avoid the installation of the .NET Client Profile, which downloads 28MB and if it's like the regular .NET Framework installer, takes forever.

I've used wxWidgets and WTL before and think both are good options. Statically linked wxWidgets executables are 30MB, but it will be packaged. WTL has a small footprint but is created with ugly code. I've used a few MSI creators but it not WiX or NSIS, which seem to be best free options.

I'm looking for any recommendations, experiences with the Client Profile installer, experiences with small, custom business apps, or any relevant advice.

Edit: I'm only making a few thousand bucks here, so I'm looking for something free or cheap (after Visual Studio, which I already own). I don't mind learning in a new language, but I'd prefer one that's growing in use.

+5  A: 

It depends on how you're distributing the app. If you have an option for cd or other physical media you can distribute the runtime via that media and 28Mb is nothing.

Otherwise you do have that 28Mb download to deal with. Your other option is to give up on .Net and choose another toolkit. The C++ Builder/Delphi option used to be pretty attractive, but I don't know what their platform looks like these days.

[update]
I've heard rumblings recently that mono is getting good enough you can use it to compile and statically link a .Net app as a native *.exe file. We'll have to see if this turns out to be a good option.

Joel Coehoorn
Installing from a CD is a good idea, it slipped my mind.
Dan Goldstein
The internet is pretty fast these days. I wouldn't let a 2 minute download scare me from using .NET. I've seen Adobe Reader updates bigger than this.
JC
it is an update too
ccook
+8  A: 

You can actually make a MFC app with fairly substantial use of large libraries (eg: boost) which will compile to under 10MB statically linked, depending on how much code you include and what features you use. Even a large-ish 32bit app is unlikely to exceed 28MB without a lot of binary resources included. The benefit of that path will likely be highly dependent on your experience with C++ and MFC, but it's certainly an option (and, as a bonus, you're not dependent on a specific version of any framework being pre-installed, or forcing any system changes at all).

Nick
I have a lot of experience with MFC. Enough to know that it's a really good option and I still don't want to use it. :-)
Dan Goldstein
@Dan why not MFC? care to elaborate?
chakrit
not even with the latest updates from MS? Besides, .NET framework requires a lot more than 28mb download for users
gbjbaanb
+3  A: 

Under the category of Relevant advice:

There's a reason why the .NET platform was built, and it wasn't because Win32 was easy to program for. There is Delphi, there is Tcl/TK, and there is MFC, but unless any of those options are easier to design and deploy than .NET, you'd be far better off swallowing the 28Mb download and designing in .NET.

With .NET (at the risk of sounding like a cheerleader), you get

  • Drag-And-Drop UI design,
  • The power of the .NET framework (let's face it, you're building for Windows -- having them do the heavy lifting is a major bonus)
  • Near platform independence (depending on how good Mono is)
  • Low-Cost

So if time is a consideration, then develop in .NET. If Time isn't a consideration, you need raw power, and you're very comfortable with C++ and MFC, then use that. Delphi is also a possibility, but the cost of their development platform is a bit steep for me.

George Stocker
I agree with you 100%. I'm comfortable with C++ and MFC but don't enjoy using it. Platform independence is not important at all.
Dan Goldstein
Go with .NET. Almost everyone is connected to the internet these days; and even if they aren't, your App could always be installed via Flashdrive or CD. If you want to fit it on a floppy disk, that's another story. :-)
George Stocker
How much more do you think Delphi costs than Visual Studio? the pro versions are similarly priced, and there's also free versions of both. And, Delphi practically *invented* RAD design and powerful frameworks...
Roddy
installing .NET without the internet is a major pain. Try it sometime, its next to impossible to get a download that isn't a 2mb 'download+install'.
gbjbaanb
Given that you can bundle the .NET runtime files with the installer, There's little reason to need an internet connection: http://msdn2.microsoft.com/en-us/library/77z6b8tz(VS.80).aspx
George Stocker
+1  A: 

Ultimately the answer is in the widget framework, the easiest frameworks wrap up the windows windowing api for you. In my experience the easiest frameworks are...

1./ Windows Forms with either c# or VB.NET (.NET)

2./ Visual Component Library (VCL) with either Delphi or C++ Builder (added advantage of being a native app, and no additional library requirements)

3./ Windows Presentation Framework (or foundation) with either C# or VB.NET

4./ MFC - (Shudder) with Visual C++

Then there are a host of other less used frameworks, like PowerBuilder etc.

Tim Jarvis
+5  A: 

Hi,

what about Qt (www.trolltech.com)? Produces small footprint apps, very easy to learn, full integration into VS200x and (what you maybe don't need) it's platform independent - and even runs on WinCE without (big) changes.

ciao, 3DH

3DH
Qt even comes with a complete IDE nowadays called QtCreator. It's bundled with the mingw gcc compiler, builtin form builder and it's quite decent for actual development.
Jasper Bekkers
+1  A: 

Even easier than writing .NET, and with a much smaller footprint than the .NET runtime - is to write the application in Visual Basic 6.

Of course, the reason why no-one has mentioned it is that it's a dying language now. But just thought I would mention it as no-one else had.

RickL
If you are an old VB6 hand, you will find that quicker than a C#/VB.Net app. IMO, C# was a step up in productivity for the C++ dudes but a step down for us ex-VB6 peeps. You can write good VB6 too. Think interfaces and composition, better most of the time even in C#. Use the Windows API if needed!
kpollock
+6  A: 

You should strongly consider Delphi or C++Builder from Codegear.

Both generate compact, native Win32 applications, built using a great two-way RAD system and the VCL framework. There's a large range of free and commercial third-party components, an active user community, and Codegear now seem fully committed to native development while keeping active in the .NET arena with the new Delphi Prism system from RemObjects.

Edit: Gortok asks "With the cost of the Delphi IDE, how can you suggest Delphi?"

Simple. I think it's worth it. I don't know how much your time is worth/charged at, but you can do the math. Delphi 2009 costs $874 list. I think Visual Studio 2008 Pro is similarly priced.

If you really have no money, then you can get Turbo Delphi free, as in beer. It's basically a cut-down version of Delphi 2006, so a bit buggier and behind, feature-wise - but still definitely usable.

Roddy
With the cost of the Delphi IDE, how can you suggest Delphi?
George Stocker
Due consider that Visual Studio also has the free Express edition that can get you up to speed relatively quickly.
Jasper Bekkers
+5  A: 

Have you ever tried Delphi?

Delphi is very good for rapid application development (RAD). You can build forms, like dotNet, dragging and dropping components. In my opinion it is perfect for business apps.

The only problem is that you will have to learn Pascal, but it should not be a problem. Delphi is compiled and very fast (similar to c++).

Why dont you download Delphi´s trial version and try it?

One plus I can think of is that you don't need to install any additional package to run your app (not dotNet runtime or c++ redistributable).

Another good point to remember is that, it has dotNet support and there is Prism.

Khalid
A: 

Paradoxically probably Qt by Trolltech... ;)

Thomas Hansen
A: 

Another option is to use Mono with mkbundle. Mkbundle takes your app and all the assemblies it references and packages them into a single binary package.

Here is a link to one of the Mono pages about it.

sgwill
+1  A: 

If you're concerned about the runtime download, just use .NET 1.1 instead of the latest and greatest .NET Framework. I think XP (or at least one of the service packs) came with it pre-installed. At some point, you have to say that if someone's using Windows 2000 or earlier, there's not much you can do for 'em.

Dave Markle
XP didn't come with .NET preinstalled.
Robert S.
But didn't it at least come in SP1?
Dave Markle
+3  A: 

What about RealBasic.

It has a managed runtime (similar to .NET but not as powerfull) and runs on windows/linux/mac and the runtime size is about 3MB

The language used is a dialect of BASIC and has a nice WYSIWYG designer with drag n drop support.

Y Low
+2  A: 

I agree, you should just code with WTL in C++ using wtlbuilder.com

Anthony Lambert
are you the real Anthony Lambert? You're a bit of a hero of mine....
Tony Lambert
+1  A: 

I suggested U++ for another question:

http://stackoverflow.com/questions/366043/what-are-some-of-the-best-cross-platform-c-ui-toolkits-today#366191

If you like C++, once you try out and work with U++, you'll be amazed by its beauty, elegance, lightweight, .NET-free as your requirement calls for and agressive use of C++.

Khnle
+1  A: 

I'd also recommend REALbasic. I use it to create a lot of Windows client applications and it works quite well for the most part.

Paul Lefebvre
+1  A: 

The Open source Free Pascal compiler with Lazarus IDE might be an option. I compile and test most of my Delphi components and libraries also with Free Pascal. For the user interface, Lazarus offers its own visual component library, FCL.

mjustin
(It's LCL. FCL is the non visual lib, including cross-DB support. LCL+FCL is roughly Delphi VCL)
Marco van de Voort