Tech Off Thread

17 posts

Why dont Micorsoft use windows forms?

Back to Forum: Tech Off
  • User profile image
    AndyStewart

    Hi

    This is just a quick question to all you Microsoft Techies. Before I start I better give myself a quick intro so not to get accused of MS bashing. I'm a professional C# developer in the Uk, so I do actually really like .net and would like to see more .net usage.

    However I feel that there are mixed words coming from MS regarding windows forms, on one hand there saying "Use Windows Forms its great, much better than HTML and asp.net" (application wise). However on the other hand, I cant think of one MS .net application(not including example apps) that uses winforms. MSN Messenger - no (even though it has .net wrote all over it), media player - no, IE - no.

    So my question in short, if winforms is so good why havent you realeased any apps using it. Also why havent you made the .net Framework a compulsory install through Auto Updates?

    As no installed framework on a machine is the obvious hold back for small ISV's.

    Thanks

    Andy

  • User profile image
    will

    In regards to MSN Messenger, the ".NET Branded" part that you see is just purely referring to the .NET Passport.

    I think when Longhorn comes out, you'll see much more applications running on .NET, or .NET with WinFX.

    I think there is some software plugins and powertoys from Microsoft that have been released recently that do make use of the .NET Framework. (Look for the OneNote powertoys...)

    I think there was a previous thread somewhere where somebody has asked about it.

    Here's one thread.

  • User profile image
    Holesinswiss

    If I'm not mistaken, the new SQL Server 2005 administration and DTS applications will use Windows Forms. Also, portions of Visual Studio .NET already use WinForms (more with each new version).

    Nearly Microsoft's entire application base are already written in C++. They would be foolish to rewrite even just the GUIs for the sake of implementing .NET and WinForms when what's there already works. It will take time, but I'm sure we'll see more WinForms apps coming out of Microsoft going forward.

  • User profile image
    ThomasAesir

    Holesinswiss wrote:

    Nearly Microsoft's entire application base are already written in C++. They would be foolish to rewrite even just the GUIs for the sake of implementing .NET and WinForms when what's there already works. It will take time, but I'm sure we'll see more WinForms apps coming out of Microsoft going forward.



    It took no time to port Quake II to .Net so why doesn't Microsoft do it to some of their popular applications?

    Here's why I wouldn't use .Net WinForms for anything but intranet development:
    • User has to download and install the framework.
    • Applications take a long time to startup.
    • .Net programs are slower than Win32.

  • User profile image
    Sven Groot

    ThomasAesir wrote:
    Holesinswiss wrote:

    Nearly Microsoft's entire application base are already written in C++. They would be foolish to rewrite even just the GUIs for the sake of implementing .NET and WinForms when what's there already works. It will take time, but I'm sure we'll see more WinForms apps coming out of Microsoft going forward.



    It took no time to port Quake II to .Net so why doesn't Microsoft do it to some of their popular applications?

    Here's why I wouldn't use .Net WinForms for anything but intranet development:
    • User has to download and install the framework.
    • Applications take a long time to startup.
    • .Net programs are slower than Win32.


    "Porting" it to .Net by throwing /clr on the compiler switches is not the same thing as using Windows Forms.

    Also, point 1 will be gone by Longhorn, point 2 isn't all that important and will get less in the future because of faster computers and the increasing likelihood of the bulk of .Net already being in memory, and point 3 is negligable (if it's true at all, I think it highly depends on what you're doing) and will also diminish over time.

    It'll come, but it takes time.

  • User profile image
    dwoodard

    You bring up some good questions.

    There is a lot of .NET / Windows Forms work going on within Microsoft. I can't speak to the teams I don't work on, but my team is in the process of writing a 99.99% NET WinForms smart client application that is due to ship midyear 2005. We can't make it 100% due to some legacy interop constraints.

    I work in Microsoft Business Solutions and a number of products in that division are going through the .NET paces.

    In my specific silo of Business Solutions, we have already shipped 2 Windows Forms applications and have one more in the design phase.

    From my perspective (not MS hype), Windows Forms has provided my team a great productivity boost as well as a huge improvement in design / code quality over our legacy application (classic ASP, COM etc.).

    I'm sure other teams have their reasons to not port to windows forms (legacy code size, development life cycle, longhorn / Whidbey sync etc.).

  • User profile image
    AndyStewart

    Thanks Guy.

    I've spent some time developing winforms apps at my company in recent weeks, and have to admit that its very easy and powerful to use. However the main problem we have is that most machines dont have the framework installed.

    What I was thinking is if MS developed say some of msn messenger in winforms, then about 90% of PC's would get the framework!(I personally dont know anyone who doesnt use msn). My obvious after thought was why havent MS used the framework, is it because its not installed on most machines meaning they've trapped themselves by not distributing it to XP machine by default.

    Andy

  • User profile image
    Sven Groot

    Whenever I set up or perform maintenance on a machine for anyone, I always install the .Net Framework 1.1 if it's not installed already. Always. Smiley

  • User profile image
    rasx

    Chris Sells and his homies won't admit it openly but Windows Forms 1.x is brittle. I was just remarking yesterday that the jump from ASP to ASP.NET was serious quantum leap. Going from a VB6 form to a Windows form is like skipping around a bit.

    First of all, threading is the problem. Windows Forms 2.0 will take care of this problem (we hope) with the Background Worker thingy. However, I have moved out of Access forms and into Windows forms with reckless abandon.

    ASP.NET applications are worth your time. They will not break your heart. Windows Forms are still toys. You can open a Windows Form designer and your controls can mysteriously vanish and then reappear after closing VS.NET. Let's see the next version.

  • User profile image
    The​Programmer

    rasx wrote:
    You can open a Windows Form designer and your controls can mysteriously vanish and then reappear after closing VS.NET.


    This is what exactly what happened to me!! And Yes,
    it is VS.Net 03!! Too bad MS does not release a
    patch for VS.Net.

  • User profile image
    Kaelan

    TheProgrammer wrote:
    rasx wrote:You can open a Windows Form designer and your controls can mysteriously vanish and then reappear after closing VS.NET.


    This is what exactly what happened to me!! And Yes,
    it is VS.Net 03!! Too bad MS does not release a
    patch for VS.Net.

    Still happens in VS.net 2005 as well, though they usually reappear if I close the designer and re-open it... I also noticed that if you mistakenly hit Ctrl+S (as I do every 60 seconds out of habit) it will save an empty form over your designer. Sad

  • User profile image
    LazyCoder

    rasx wrote:
    Chris Sells and his homies won't admit it openly but Windows Forms 1.x is brittle.

    ...

    First of all, threading is the problem. Windows Forms 2.0 will take care of this problem (we hope) with the Background Worker thingy.

    ...

    Windows Forms are still toys. You can open a Windows Form designer and your controls can mysteriously vanish and then reappear after closing VS.NET. Let's see the next version.


    Is this a problem with the designer in Visual Studio or with the Framework itself? Can you elaborate on the threading problem? I'm a web developer who's looking to get back into WinForms development for some small personal projects.

  • User profile image
    Charles

    I've been working deeply with Windows Forms 2.0 Beta 1 all day and I'm very impressed so far. I would say that Windows Forms is a very sophisticated and powerful technology (certainly not a toy) that will make the transition from Web Dev to Windows Dev a lot prettier and much more productive than it would be should you decide to jump into the COM/Win32 world directly. Still, there will be much to learn.  

    The strange UI phenomena happening on the Form Design surface is an interesting bug. Can you provide more details? I'll pass it along to the VS people. One thing I can tell you, to answer the question, it's most likely not a bug in the Framework. The Designer is a rather complex piece of technology. I've had strange experiences working with the designer too (well, when writing code in the InitializeComponent method, which is explicitly not recommended...)

    Keep on posting,

    Charles  

    EDIT: Fixed bad grammar

  • User profile image
    Kaelan

    Charles wrote:
    The strange UI phenomena happening on the Form Design surface is an interesting bug. Can you provide more details? I'll pass it along to the VS people. One thing I can tell you, to answer the question, it's most likely not a bug in the Framework. The Designer is a rather complex piece of technology. I've had strange experiences working with the designer too (well, when writing code in the InitializeComponent method, which is explicitly not recommended...)

    I'd provide more details if I had any... I haven't noticed any trends other than it happens randomly, and somewhat often, and resolves itself if i  close the designer and reopen it. It seems that it's not loading the designer at all, because if I hit save it erases it.

  • User profile image
    Frank Hileman

    Usually that problem is caused by having uncompiled or uncompilable custom controls in your project, that are used within a form or higher level user control. If you have the form open in the designer, the custom controls cannot be instantiated if they are uncompiled or uncompilable. So they get deleted, and the form document is marked "changed". If you don't notice that, and hit build, then the corrupted parent form gets saved, and wham, you lost some work.

    If you put your custom components into a separate assembly and solution that problem goes away -- as long as you do a build on it first.

    We have the same problem with VG.net and there is nothing we can do about it because it is simply the MS design.

  • User profile image
    staceyw

    "First of all, threading is the problem. Windows Forms 2.0 will take care of this problem (we hope) with the Background Worker thingy."

    No problem with threading today.  You just need to invoke any updates on the gui thread which can be done a number of ways.  For example, here is a bone simple way to update a richtextbox on the gui thread from any worker thread without the caller having to know about delegates and events - just have a ref to the form and call the public method with the text - pretty simple:

      private delegate void UpdateDelegate(string message);

      public void UpdateRTB(string message)
      {
       if ( InvokeRequired )
       {
        UpdateDelegate ud = new UpdateDelegate(UpdateRTB);
        Invoke(ud, new object[]{message});
       }
       else
       {
        this.rtbOutput.AppendText(message + "\n");
       }
      }

  • User profile image
    phunky_avoc​ado

    I wrote a commercial OCR (optical character recognition) + document scanning WinForm application in C# and it rocked (IMHO).  Includes threading, GDI+, MAPI support, Win32 junk, security, you name it... 

    So, I don't think WinForms is a toy at all. 

    The only people I know who say WinForms is a toy are some old C++ purists who I think are feeling a bit passed over. 

    rasx wrote:
    Chris Sells and his homies won't admit it openly but Windows Forms 1.x is brittle. I was just remarking yesterday that the jump from ASP to ASP.NET was serious quantum leap. Going from a VB6 form to a Windows form is like skipping around a bit.

    First of all, threading is the problem. Windows Forms 2.0 will take care of this problem (we hope) with the Background Worker thingy. However, I have moved out of Access forms and into Windows forms with reckless abandon.

    ASP.NET applications are worth your time. They will not break your heart. Windows Forms are still toys. You can open a Windows Form designer and your controls can mysteriously vanish and then reappear after closing VS.NET. Let's see the next version.

Comments closed

Comments have been closed since this content was published more than 30 days ago, but if you'd like to continue the conversation, please create a new thread in our Forums, or Contact Us and let us know.