top | item 12351192

(no title)

boduh | 9 years ago

What kind of apps do you have in mind? Care to share more details?

discuss

order

spapas82|9 years ago

General purpose apps -- actually, what I had in mind was rather simple, just one dialog window that would act as a GUI to a command line application (that already exists in the user's system). This would be mainly for people that can't use the command line.

However, to elaborate more, I'd like to add a couple of nice -to-haves (these are specific for me but I think that most of the following could generally be nice-to-haves for any application targeted to non-experienced users):

- The size of the resulting application shouldn't be proportionaly big. For that simple app I described I would expect a couple of MB (I think that's a problem with electron/nw.js apps)

- The user ideally shouldn't need to install anything else - everything should be contained in the application, so python based apps are probably not very good. Also, for the same reason I had some really bad experiences with applications that required a very specific version of .NET that would take half an hour to install on my system :(

- There shouldn't be any installation - ideally, just give the user a zip containing a .exe and maybe a couple of libraries (even better if these libs could be statically linked to the exe)

- The app should be able to access the full windows API - I want to be able to display file open dialog, write some configuration options to AppData etc

Before 15 years I know the answer to my needs was to just use VB (or C++ with MFC for those that knew it), before 10 years I guess Java with Swing (or AWT)... Probably even now these could also be used, however I was thinking if there are some other methods of developing desktop windows application I wasn't aware of.

Quppa|9 years ago

Do you need to target versions earlier than Windows 10? If so, you'll have to rule out a Universal Windows Platform app (which might otherwise suit your needs, though you wouldn't be able to use it to write to AppData).

A Windows Presentation Foundation or Windows Forms app targeting .NET 4.0 will get you pretty good compatibility - Windows 8 and above come with it pre-installed* and it's an optional Windows Update for Windows XP/Vista/7. I don't think the XAML learning curve is as steep as some people claim, but it'll still be quicker to hack something together in WinForms over WPF if you haven't used the latter before.

Also check out the Desktop App Converter for Windows 10 - you can now package up a WPF/WinForms/Win32/etc. app into a UWP app for Windows 10 users and pick up some of the benefits that those apps have†.

* But also heed Raymond Chen: https://blogs.msdn.microsoft.com/oldnewthing/20110404-00/?p=...https://developer.microsoft.com/en-us/windows/bridges/deskto...

emjoes1|9 years ago

Prob C++... At least that is the only thing that I believe will meet your requirements exactly.

I ended up (a few years back) going with WPF (Windows Presentation Foundation) in C# targeting .NET client profile. Of course you still need .NET, however, the client profile is a much smaller install than the full version and I have no problems going from .NET 4 to 4.5. No specific version is needed unless you want to use new features.

In regards to your needs here is a couple of reasons I like WPF: -The entire GUI can be written in markup XAML (an XML based markup language) so its kind of web like. You can use the GUI if you like but doing it in XAML forces good design patterns and IMO is easier. -"Click Once Deployment" allows you to publish the app build to a network share which can be run directly over the network (no local install). There are various options so if you choose to run locally you can. If you update your app, you simply publish again, and when the end users launches the app again it will be updated.

You can bundle dependencies so the first install would include the large (41MB) .NET client profile but after that it would just be the size of your app. This has worked well for me to allow users to install/update the apps over slow VPN connections.

aaronhoffman|9 years ago

For this situation I would recommend a "Windows Forms" app. You can include the framework/base class library bits you need in the distribution package if you think they won't already be available on the machine

majewsky|9 years ago

> everything should be contained in the application, so python based apps are probably not very good.

http://www.py2exe.org/ -- but I don't know how large the resulting EXEs are, so that might break your size requirement.

WayneBro|9 years ago

You want WinForms then. UWP is right out the door with you last requirement. WPF is out with the 2nd and 3rd ones if you're targeting Win7.

realharo|9 years ago

Regarding Java, Swing has sort of fallen out of favor and JavaFX is not the "standard" UI library.

Asooka|9 years ago

The only thing that fits the bill is C++ with the basic Win32 API that you're guaranteed ships with every version of Windows. But you'll still need to bundle the Microsoft VisualC++ runtime installer. To save yourself from writing raw Win32, I would suggest WxWidgets. You can link statically to the library and compile in only what you need, keeping size manageable.