Dotnet Core has a transformation, he uses the DLL format instead of EXE as the general execution format, and then the command line dotnet YourApp.dll to run the program. To increase the force, double-click to run, you can use the following scenarios:
Scenario one with BAT file
You can write a bat to execute, such as the Mylib.bat file content:
@dotnet Mylib.dll
@pause
Scenario two releases the specified operating environment
With command line: dotnet publish-f netcoreapp2.1-c release-r win-x64
Where-f Specifies the framework,-r specifies the running environment. After publishing, a directory of more than 60 m is generated. Where the Publish subdirectory carries the entire dotnet core framework, it can be copied to the specified system environment for execution (it is said to install VC + + 2015 runtime).
Spicy big, of course, is not what we want, we need only EXE file format. After testing, published directory removal publish subdirectory, the remaining 1m multi-point EXE related files can be run, provided that the relevant Dotnet core framework is installed.
Additional Information
Tested with a virtual machine. In the WinXP will be prompted is not a valid 32-bit program, Netcore does not support WinXP, Microsoft this dishonest trader.
Official information shows the minimum support Win7, and then install Win7 SP1 x64, or can not directly run, will prompt loading DLL, Baidu, after testing is a lack of a patch: WINDOWS6.1-KB2533623-X64.MSU
Download: Blog Park main station
Microsoft: https://www.microsoft.com/zh-CN/download/details.aspx?id=26764
Well, Microsoft's always going to make you a bit of a problem.
dotnet core how to compile EXE