What kind of VS project to use?

Ivica Nesic 21 Reputation points
2021-05-24T12:18:30.607+00:00

Greetings community,

This is somehow beginner's question, because I don't really have an experience with this.

My experience level: Last 10 years, I've been working with Excel and VBA, as well as small windows forms application that were pulling data from SQL server, and creating Excel files as report. I've been using VB.NET

However, after one presentation, I've been told that I should try WPF for faster UI, and I should start using C# instead of VB for easier finding examples and answers on my questions.

My intention are Windows desktop apps, not mobile at the moment.

So, when I start VS and its "Create a new project" wizard and select filters at "C#", "Windows" and "Desktop", few dozens of choices comes up, and amongst them are "WPF Application" (with .NET Core) and "WPF App (.NET Framework). My apps should not go to the internet, only to machines that are on the local network (it's a small biz). Which one should I choose so I could start learning what I was suggested?

My apologies for my English, and thanks for your answers.

Developer technologies | C#
0 comments No comments
{count} votes

Accepted answer
  1. Karen Payne MVP 35,586 Reputation points Volunteer Moderator
    2021-05-24T13:27:03.09+00:00

    Hello,

    First off much of my reply a) comes from experience b) taking into account your background. In some cases I'm sparse and other places elaborate more. In the end I feel my recommendation and suggestions should give you enough information to make an informed choice.

    In regards to C# vs VB.NET finding assistance and code samples, there are indeed more out there documentation wise and people in C# than VB.NET along with VB.NET is not really going any place in regards to improvements.

    Concerning which type of project

    • WPF is a great choice although coupling this project type with C# with a VBA background will take a decent time to adjust.
    • Windows Forms using .NET Framework/C# is very solid for desktop applications.
    • Windows Forms using .NET Framework Core/C# is also a good choice while coming from VBA the difference between using .NET Framework and .NET Framework Core is not really going to be notice while someone who has been work with .NET to .NET Core will notice a difference.

    Is one better performance wise? I'd say the first part to answer this is, it depends on how well user code is written. If the code is poorly written in any of these types of projects nothing will assist with performance which can happen when first learning.

    Compelling reason for WPF

    • Richer user interface than Windows Forms any flavor
    • More emphasis on OOP

    Downside to WPF

    • Longer learning curve than Windows Forms when done correctly

    Downside to .NET Core (presently)

    • Windows Forms is considered in preview mode, all the bugs have not be handled

    Upside to Windows Forms classic (.NET Framework 4.8 and lower)

    • Proven technology
    • Not missing much from .NET Core

    When looking at the three for you my recommendation is Windows Forms classic, not Windows Forms .NET Core unless you have special needs for the user interface that Windows Forms is not capable of.

    Go with Windows Forms classic, write the bulk of code in class projects called by code in Windows Forms. Later if you decide to roll with .NET Core it's an easier transition.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.