WebMAP: WinForms to Web is a tool designed to convert .NET Framework apps based on C# and Windows Forms to a modern web architecture:
Business logic source code is converted to ASP.NET Core.
The user interface(UI) rendered as HTML using Angular, JavaScript, and KendoUI.
For VB.Net, contact us for alternatives.
Code Conversions
Here is an example of the very first WinForms application any programmer would do. The program consists of a form and a button that changes the text. The comparison side by side with the converted app shows minimum alterations:
The emphasis of WebMap: WinForms to Web is the transparency for the developer from the original application to the converted one, which is also reflected in the following example code from C# to WebMAP.
The automation of web processes is clear for the user, thanks to internal libraries such as Weaving, that provides functions to interact with the BackEnd/CoreServices. So, the converted code does not add unnecessary complexity and maintains its similarity to the original.
The UI represents a new challenge to convert, and so, we tackle this problem by converting the Windows.Forms into an Angular component divided into three main files:
HTML
CSS
TypeScript
For this same example, the form called Form1.cs is converted as:
Source code Form1.designer.cs
namespaceHelloWorld{partialclassForm1 { /// <summary> /// Required designer variable. /// </summary>privateSystem.ComponentModel.IContainer components =null; /// <summary> /// Clean up any resources being used. /// </summary> /// <paramname="disposing">true if managed resources should be disposed; otherwise, false.</param>protectedoverridevoidDispose(bool disposing) {if (disposing && (components !=null)) {components.Dispose(); } base.Dispose(disposing); } Windows Form Designer generated codeprivateSystem.Windows.Forms.Button button1;privateSystem.Windows.Forms.Label label1; }}
Every control declared inside the Form1.designer.cs file will have its corresponding HTML tag as is the case with Button.
Now you have covered the basics of what WebMAP: WinForms to Web conversion looks like. Let's proceed with a further explanation of how to run a full conversion process and run the output application by yourself.