Skip to main content

Run Network Manager

  1. Make sure you have the latest code from the epanetconsolecore repository.
  2. Open the epanetconsolecore.sln file with VS 2022.

Create new DB and Run Migrations

  1. Create a new database matching the name format: network_m_d_yyyy, i.e. mtw_5_2_2025.
  2. In the epanetconsolecore solution, right click on EN2PostgresContext and set it as startup project.
  3. In the EN2PostgresContext project, make sure the two files EN2PostgresContext.cs and EN2PostgresContextFactory.cs reference the proper database in their connection strings.
  4. In the VS toolbar, select Tools > NuGet Package Manager > Package Manager Console.
  5. In the console, click the dropdown to ensure the EN2PostgresContext project is selected.
  6. Run the command Update-Database
  7. Repeat all steps 1-6 for the SDPostgresContext project.

Run Network Manager Project

  1. Right click on the NetworkManager project and set it as startup project.
  2. Open the NetworkManager.appsettings.json file and configure the connection string and input file path.
  3. Run the project.