Setting up the development environment - Mago-DACH-Hub/documentation GitHub Wiki
Development Environment
To start developing a Mago Application it's necessary to set up a Development environment:
Prepare your machine:
- Download the latest Mago Build using your Microarea credentials
- Install SQL Server Express Dev
- Install SQL Server Management Studio
- Install the necessary Windows Features
(at least
Internet Information Services -> Web Management Tools -> IIS 6 Management Compatibility -> IIS-Metabasis & IIS6-Configuration Compatibility
) - Download Visual Studio 2019 (Direct Download: Community | Professional | Enterprise)
- Download the VS2019 install configuration. More Details here
- Install Visual Studio 2019 importing the configuration.
- Start VS2019
- Install the microarea addon under
Extensions -> Manage Extensions
and search for "Microarea"
Create your development environment:
-
Create a folder to contain the development environment under
C:\
(e.g.C:\DEV\DevDesktop_351
; it's best to use only alphanumeric symbols as well as '-' or '_'. Try to not nest the subfolders too much to avoid issues due to excessive long pathnames and ABSOLUTLEY AVOID SPACES!) -
Extract TaskBuilderStudio.zip from the Mago Build into the previously created folder
-
Extract Mago4 Sources.zip into the previously created folder
-
Open the solution under
Standard\Applications\ERP\ERP.sln
(it's recommended to start Visual Studio as administrator) -
Try to build Mago 4
-
If you run into problems, open Powershell, browse to your development path and unblock the necessary files using these "Unblock-File" commands:
Unblock-File ./Standard/Applications/ERP/Barcode/Microarea.ERP.BarcodeComponents/ScanDataCtrl.cs Unblock-File ./Apps/TBApps/Debug/* Unblock-File ./Apps/TBApps/Release/* Unblock-File ./Apps/AdministrationConsole/Release/*
-
Create a IIS Directory by VS2019 under
Extensions -> Microarea Tools -> Create IIS Directory
and choosing your development environment folder -
Open the Administration Console under
/Apps/AdministrationConsole/Release/
-
Register Mago4 using the Serial number you can find here
└ On how to register TBS / Reporting Studio, check this wiki's Reporting Studio section.
-
Login to your server and create a new system database
-
Create a new company and company database by right clicking
System Administrator\Companies
on the left -
Right click on the new company and select "Create/update database structure" and click on create (you also might want to import default data)
-
Opt.: Right click on the new company and select "Manage company data" -> "Manage Sample Data" and click through the dialogue
Your Mago4 development environment should now be fully setup.
Starting Mago through Visual Studio
Before you start developing , keep in mind that you have to do two more steps to run / debug your solution.
- Opening your Solution, it might be necessary to retarget your solution. If not prompted when you open your solution for the first time, you can always do so be clicking on the index tab
Project -> Retarget solution
and there, change theWindows SDK Version
to the "(latest installed version)". - To start Mago4 Desktop through Visual Studio, you can register the starting exe here:
Debug -> Properties (last menu item) -> Configuration Properties -> Debugging -> Command -> "{MagoDev folder}\Apps\TbAppManager\debug\TbAppManager.exe"
Generating an application with tblegacy
If you want to use the tb-legacy tool to generate an application:
- Install nodejs 8.9 or higher
- Follow the tb-legacy install instructions
On how to use the tb-legacy tool and for more development details, check out the official tb-legacy wiki or this wiki's development section.