Open Touryo is an application framework based on .NET Framework and .NET Core.
The programs of Open Touryo are available in the following repositories:
- OpenTouryoTemplates repository
- Summary
The programs in this repository are the development infrastructure (project template) of the programs using Open Touryo.
And the programs are partitioned into the folders for each version of Visual Studio. - Intended User
The application developers using Open Touryo.
- Summary
- OpenTouryo repository (Current repository)
- Summary
The programs in this repository are the matrix of OpenTouryoTemplates repository.
(First, the features of Open Touryo are implemented in this repository. And then, the features are introduced into OpenTouryoTemplates repository.) - Intended User
Open source developers.
- Summary
Therefore, the users who use Open Touryo in a system development project need to use OpenTouryoTemplates repository.
The following contents are the usage of Open Touryo for open source developers.
Click here for Japanese version of this file.
You can run the sample application bundled with Open Touryo according to the following steps.
Notation Optional:
Open Touryo supports the following DBMSs and data providers. But the data providers, having the notation optional, are not included in the programs of Open Touryo. When using the DBMSs and data providers having the notation optional, download the data provider manually, and modify the data access project of Open Touryo, that is DamXXX.csproj, to refer the data provider.
Install Visual Studio 2015 beforehand.
If you develop for .NET Standard or .NET Core, install Visual Studio 2017 beforehand.
see: https://docs.microsoft.com/ja-jp/dotnet/core/windows-prerequisites
Further, when implementing or testing the data access class, install the DBMS(s) to be used.
Open Touryo supports the following DBMSs:
- SQL Server
(You can use an arbitrary version of SQL Server. And you can use different editions than Express Edition.) - Oracle Database (including Express Edition)
- IBM DB2 ... optional
- HiRDB ... optional
- MySQL
- PostgreSQL
Copy root folder to just under C drive. If not, the build may fail for the Windows maximum path length limitation.
The correspondence between the DBMSs and the data providers is as follows.
- Oracle
- Oracle.DataAccess.dll ... optional
- Oracle.ManagedDataAccess.dll
- IBM DB2
- IBM.Data.DB2.dll ... optional
- HiRDB
- x86: pddndp40.dll, pddndpcore40.dll ... optional
- x64: pddndp40x.dll, pddndpcore40x.dll ... optional
- MySQL
- MySql.Data.dll
- PostgreSQL
- Npgsql.dll
Sample application requires Northwind database.
So, download the setup script installer of Northwind database from the following Microsoft site and install.
- Download: NorthWind and pubs Sample Databases for SQL Server 2000 - Microsoft Download Center
http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=23654
When completing the installation, SQL Server 2000 Sample Databases folder is created in C drive.
When using SQL Server 2012 or later, open instnwnd.sql file in an editor and comment out the following code.
Note:
Because sp_option system stored procedure does not exist in SQL Server 2012 or later, this step is required.
exec sp_dboption 'Northwind','trunc. log on chkpt.','true'
exec sp_dboption 'Northwind','select into/bulkcopy','true'Execute the following command at a command prompt.
Note:
In the following command, the path of the folder that contains SQLCMD.EXE changes according to the version of SQL Server. Execute command after confirming the path of folder in your environment.
"C:\Program Files\Microsoft SQL Server\100\Tools\Binn\SQLCMD.EXE" -S localhost\SQLExpress -E -i "C:\SQL Server 2000 Sample Databases\instnwnd.sql"- Create an empty database in each DBMSs.
- Create test table in the database by running C:\root\files\resource\Sql\[DBMS Name]\TestTable.txt.
When using Open Touryo, it is necessary to build programs by running the batch files using MSBuild only at the first time.
Note:
Open Touryo Template Base contains two parts:
- Framework (Base class 1 and base class 2)
- Sample application (Subclass)
It is necessary to copy the deliverables generated by building, that is, dll files to the default folder of Open Touryo.
Therefore, it is necessary to run the batch files which execute a series of build processes.
The batch files are stored in the following folder:
- C:\root\programs\CS
- C:\root\programs\VB
By executing 0_ExecAllBat.bat, you can execute necessary batch files together. Refer to the table below, check the necessary batch to be executed, customize 0_ExecAllBat.bat as necessary, and execute it.
| # | Batch file name | Description | Existence | |
| C# | VB | |||
| 1 | 0_ExecAllBat.bat | Perform a batch build using the following files: Customize as needed. | ○ | ○ |
| 2 | 1_DeleteDir.bat | Delete (Clean up) the folders that are generated by building. | ○ | ○ |
| 3 | 1_DeleteFile.bat | Delete (Clean up) the temporary files. | ○ | ○ |
| 4 | 2_Build_NuGet_net45.bat | Build the framework (Base class 1 and library part) to make NuGet package that targets .NET Framework 4.5.2. | ○*1 | - |
| 5 | 2_Build_NuGet_net46.bat | Build the framework (Base class 1 and library part) to make NuGet package that targets .NET Framework 4.6. | ○*1 | - |
| 6 | 2_Build_NuGet_net47.bat | Build the framework (Base class 1 and library part) to make NuGet package that targets .NET Framework 4.7. | ○*1 | - |
| 7 | 2_Build_NuGet_net48.bat | Build the framework (Base class 1 and library part) to make NuGet package that targets .NET Framework 4.8. | ○*1 | - |
| 8 | 2_Build_NuGet_netstd20.bat | Build the framework (Base class 1 and library part) to make NuGet package that targets .NET Standard 2.0. | ○*1, *3 | - |
| 9 | 2_Build_NuGet_netstd21.bat | Build the framework (Base class 1 and library part) to make NuGet package that targets .NET Standard 2.1. | ○*1, *3 | - |
| 10 | 2_Build_NuGet_nettcore30.bat | Build the framework (Base class 1 and library part) to make NuGet package that targets .NET Core 3.0. | ○*1, *3 | - |
| 10 | 2_Build_NuGet_nettcore50.bat | Build the framework (Base class 1 and library part) to make NuGet package that targets .NET 5. | ○*1, *3 | - |
| 10 | 2_Build_NuGet_nettcore60.bat | Build the framework (Base class 1 and library part) to make NuGet package that targets .NET 6. | ○*1, *3 | - |
| 11 | 3_Build_Business_net45.bat | Build a framework (base class 2, library part) of Business namespace that targets .NET Framework 4.5.2. | ○ | |
| 12 | 3_Build_Business_net46.bat | Build a framework (base class 2, library part) of Business namespace that targets .NET Framework 4.6. | ○ | |
| 13 | 3_Build_Business_net47.bat | Build a framework (base class 2, library part) of Business namespace that targets .NET Framework 4.7. | ○ | |
| 14 | 3_Build_Business_net48.bat | Build a framework (base class 2, library part) of Business namespace that targets .NET Framework 4.8. | ○ | |
| 15 | 3_Build_BusinessRichClient_net45.bat | Build a framework for rich client application (base class 2, library part) of Business namespace that targets .NET Framework 4.5.2. | ○*2 | |
| 16 | 3_Build_BusinessRichClient_net46.bat | Build a framework for rich client application (base class 2, library part) of Business namespace that targets .NET Framework 4.6. | ○*2 | |
| 17 | 3_Build_BusinessRichClient_net47.bat | Build a framework for rich client application (base class 2, library part) of Business namespace that targets .NET Framework 4.7. | ○*2 | |
| 18 | 3_Build_BusinessRichClient_net48.bat | Build a framework for rich client application (base class 2, library part) of Business namespace that targets .NET Framework 4.8. | ○*2 | |
| 19 | 3_Build_Business_netcore20.bat | Build a framework (base class 2, library part) of Business namespace that targets .NET Core 2.0. | ○*3 | - |
| 20 | 3_Build_Business_netcore30.bat | Build a framework (base class 2, library part) of Business namespace that targets .NET Core 3.0. | ○*3 | - |
| 20 | 3_Build_Business_netcore50.bat | Build a framework (base class 2, library part) of Business namespace that targets .NET 5. | ○*3 | - |
| 20 | 3_Build_Business_netcore60.bat | Build a framework (base class 2, library part) of Business namespace that targets .NET 6. | ○*3 | - |
| 21 | 3_Build_BusinessRichClient_netcore30.bat | Build a framework for rich client application (base class 2, library part) of Business namespace that targets .NET Core 3.0. | ○*2, *3 | - |
| 21 | 3_Build_BusinessRichClient_netcore50.bat | Build a framework for rich client application (base class 2, library part) of Business namespace that targets .NET 5. | ○*2, *3 | - |
| 21 | 3_Build_BusinessRichClient_netcore60.bat | Build a framework for rich client application (base class 2, library part) of Business namespace that targets .NET 6. | ○*2, *3 | - |
| 22 | 4_Build_CopyAssemblies.bat | Copy the primary output of the above build to the reference folder. | ○ | |
| 23 | 4_Build_Framework_Tool.bat | Build the .NET Framework-based tools bundled with Open Touryo. | ○ | - |
| 24 | 4_Build_Framework_ToolCore.bat | Build the .NET Core-based tools bundled with Open Touryo. | ○*3 | - |
| 25 | 5_Build_Bat_sample.bat | Build the .NET Framework-based sample application. (Batch application) | ○*4 | |
| 26 | 5_Build_BatCore_sample.bat | Build the .NET Core-based sample application. (Batch application) | ○*3, *4 | - |
| 27 | 5_Build_2CS_sample.bat | Build the .NET Framework-based sample application. (Two-tier client server application) | ○*4 | |
| 28 | 5_Build_2CSCore_sample.bat | Build the .NET Core-based sample application. (Two-tier client server application) | ○*3, *4 | - |
| 29 | 6_Build_WSSrv_sample.bat | Build the .NET Framework-based sample application. (Web services (Server-side logic)) | ○*4 | |
| 30 | 6_Build_WSSrvCore_sample.bat | Build the .NET Core-based sample application. (Web services (Server-side logic)) | ○*3, *4 | - |
| 31 | 7_Build_Framework_WS.bat | Build the .NET Framework-based framework. (Service interface) | ○*4 | |
| 32 | 7_Build_Framework_WSCore.bat | Build the .NET Core-based framework. (Service interface) | ○*3, *4 | - |
| 33 | 8_Build_WSClnt_sample.bat | Build the .NET Framework-based sample application. (Web service client) | ○*4 | |
| 34 | 8_Build_WSClntCore_sample.bat | Build the .NET Core-based sample application. (Web service client) | ○*3, *4 | - |
| 35 | 10_Build_WebApp_sample.bat | Build the sample web application. (ASP.NET) | ○*4 | |
| 36 | 10_Build_WebAppCore_sample.bat | Build the sample web application. (ASP.NET Core) | ○*3, *4 | - |
| 37 | 99_BuildLibsAtOtherRepos.bat | Batch file for to use the Business namespace of the repository in other repositories. (using OpenTouryoTemplates-master branch) | ○ | - |
| 38 | 99_BuildLibsAtOtherReposInTimeOfDev.bat | Batch file for to use the Business namespace of the repository in other repositories. (using OpenTouryo-develop branch) | ○ | - |
| 39 | y_Build_TestCode.bat | Perform batch build and execution of the following test code. | ○ | - |
| 40 | y_Build_TestCode_Public.bat | Build and execute the test code of the following Public namespace. | ○ | - |
| 41 | y_Build_TestCode_SecCUI.bat | Build and execute the CUI test code of the following Public.Security namespace. | ○ | - |
| 42 | y_Build_TestCode_SecCUI.sh | Build and execute the CUI test code of the following Public.Security namespace usin WSL. | ○ | - |
| 43 | y_Build_TestCode_SecGUI.bat | Build and execute the GUI test code of the following Public.Security namespace. | ○ | - |
| 44 | z_ChangePackages_net45.bat | Batch file to switch packages.config when creating NuGet package. (for .NET Framework 4.5.2) | ○ | - |
| 45 | z_ChangePackages_net46.bat | Batch file to switch packages.config when creating NuGet package. (for .NET Framework 4.6) | ○ | - |
| 46 | z_ChangePackages_net47.bat | Batch file to switch packages.config when creating NuGet package. (for .NET Framework 4.7) | ○ | - |
| 47 | z_ChangePackages_net48.bat | Batch file to switch packages.config when creating NuGet package. (for .NET Framework 4.8) | ○ | - |
| 48 | z_Common.bat | Common settings (for MSBuild) | ○ | ○ |
| 49 | z_Common2.bat | Common settings (for Visual Studio) | ○ | ○ |
*2 Need to run when developing rich client application.
*3 Need to run when developing application that targets .NET Standard or .NET Core.
*4 Select according to the actual architecture.
-
If necessary, revise the environment variable BUILDFILEPATH in z_Common.bat according to the build environment.
-
The libraries which are used by Open Touryo Template Base for Visual Studio 2015 are downloaded by NuGet. NuGet libraries might not be downloaded normally under proxy environment. So, when using proxy environment, create environment variable http_proxy as follows:
- Open C:\root\programs\CS\z_Common.bat and C:\root\programs\VB\z_Common.bat in an editor.
- By default, the code which creates environment variable http_proxy is commented.
So, uncomment this code by removing '@rem'. - Set your proxy information in environment variable http_proxy.
-
When the following error occurred at build time, install Windows SDK for Windows 8. (Refer to issue of Open Touryo.)
C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(2863,5): error MSB3086: Task could not find "AL.exe" using the SdkToolsPath "" or the registry key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v8.0A\WinSDK-NetFx40Tools-x86". Make sure the SdkToolsPath is set and the tool exists in the correct processor specific location under the SdkToolsPath and that the Microsoft Windows SDK is installed
Open a command prompt as an administrator and execute the following commands.
sc config aspnet_state start= auto
net start aspnet_stateOpen the following file.
- Open web.config or app.config (for .NET Core, appsettings.json) and revise the values in connectionStrings section according to the actual database environment.
- Run the sample application.
At the login screen, enter the arbitrary alphanumeric characters. (By default, the password authentication is not executed.)
- ASP.NET Web Forms
- C:\root\programs\CS\Samples\WebApp_sample\WebForms_Sample\WebForms_Sample.sln
- C:\root\programs\VB\Samples\WebApp_sample\WebForms_Sample\WebForms_Sample.sln
- ASP.NET MVC
- C:\root\programs\CS\Samples\WebApp_sample\MVC_Sample\MVC_Sample.sln
- C:\root\programs\VB\Samples\WebApp_sample\MVC_Sample\MVC_Sample.sln
- Windows Forms
- C:\root\programs\CS\Samples\2CS_sample\2CSClientWin_sample\2CSClientWin_sample.sln
- C:\root\programs\VB\Samples\2CS_sample\2CSClientWin_sample\2CSClientWin_sample.sln
- WPF
- C:\root\programs\CS\Samples\2CS_sample\2CSClientWPF_sample\2CSClientWPF_sample.sln
- C:\root\programs\VB\Samples\2CS_sample\2CSClientWPF_sample\2CSClientWPF_sample.sln
- Windows Forms
- Windows forms application
- C:\root\programs\CS\Samples\WS_sample\WSClient_sample\WSClientWin_sample\WSClientWin_sample.sln
- C:\root\programs\VB\Samples\WS_sample\WSClient_sample\WSClientWin_sample\WSClientWin_sample.sln
- ClickOnce application
C:\root\programs\CS\Samples\WS_sample\WSClient_sample\WSClientWinCone_sample\WSClientWinCone_sample.sln
- Windows forms application
- WPF
- C:\root\programs\CS\Samples\WS_sample\WSClient_sample\WSClientWPF_sample\WSClientWPF_sample.sln
- C:\root\programs\VB\Samples\WS_sample\WSClient_sample\WSClientWPF_sample\WSClientWPF_sample.sln
- C#
- C:\root\programs\CS\Frameworks\Infrastructure
- C:\root\programs\CS\Frameworks\Infrastructure\ServiceInterface\ASPNETWebServiceCore
- VB
...
- C#
- C:\root\programs\CS\Frameworks\Tools
- VB
...
- C#
- C:\root\programs\CS\Samples4NetCore
- VB
...
Refer to License directory.
If you find the bug while you are using Open Touryo, create an new issue.
Open Touryo community confirms the issue and takes appropriate actions.
For the method of creating Open Touryo NuGet packages, see this article.
- The libraries that can be obtained from package manager, that is NuGet or npm, are not bundled in Open Touryo. So, you don't have to export the libraries.
- If necessary, you have to obtain and export the other libraries, that is the libraries that can not be obtained from package manager, on your own. In this case, you have to attach the license of the libraries to be used to the license of Open Touryo.
The documents in OpenTouryoDocument repository are useful when using Open Touryo.
- Introduction
You can see the introduction materials, such as PowerPoint slides. - User Guide
You can confirm the structure of Open Touryo and the specification of each feature. - Tutorial
You can see the first step guide of Open Touryo.