mirror of
https://github.com/ElectronNET/Electron.NET.git
synced 2026-02-03 21:25:13 +00:00
webapplication does not appear. #48
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @niufwshd on GitHub (Nov 4, 2017).
os: win10 64bit .net core 2.0.2 vs2017 15.4
i followed the readme's step,finally the console window appear:
Start Electron Desktop Application...
Microsoft Windows [版本 10.0.14393]
(c) 2016 Microsoft Corporation。保留所有权利。
C:\Users\Think\Documents\Visual Studio 2017\Projects\WebApplication1\ASPNETCORE2>dotnet publish -r win10-x64 --output "C:\Users\Think\Documents\Visual Studio 2017\Projects\WebApplication1\ASPNETCORE2\obj\Host\bin"
用于 .NET Core 的 Microsoft (R) 生成引擎版本 15.4.8.50001
版权所有(C) Microsoft Corporation。保留所有权利。
ASPNETCORE2 -> C:\Users\Think\Documents\Visual Studio 2017\Projects\WebApplication1\ASPNETCORE2\bin\Debug\netcoreapp2.0\win10-x64\ASPNETCORE2.dll
ASPNETCORE2 -> C:\Users\Think\Documents\Visual Studio 2017\Projects\WebApplication1\ASPNETCORE2\obj\Host\bin\
C:\Users\Think\Documents\Visual Studio 2017\Projects\WebApplication1\ASPNETCORE2>
Start npm install...
Microsoft Windows [版本 10.0.14393]
(c) 2016 Microsoft Corporation。保留所有权利。
C:\Users\Think\Documents\Visual Studio 2017\Projects\WebApplication1\ASPNETCORE2\obj\Host>npm install
and hanged.
then I switch to visual stuido and pressed f5
a console weindow appeared:
info: Microsoft.AspNetCore.DataProtection.KeyManagement.XmlKeyManager[0]
User profile is available. Using 'C:\Users\Think\AppData\Local\ASP.NET\DataProtection-Keys' as key repository and Windows DPAPI to encrypt keys at rest.
Hosting environment: Production
Content root path: C:\Users\Think\Documents\Visual Studio 2017\Projects\WebApplication1\ASPNETCORE2\bin\Debug\netcoreapp2.0\win10-x64
Now listening on: http://localhost:5000
Application started. Press Ctrl+C to shut down.
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[1]
Request starting HTTP/1.1 GET http://localhost:5000/home/index
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[2]
Request finished in 313.9332ms 404
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[1]
Request starting HTTP/1.1 GET http://localhost:5000/
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[2]
Request finished in 2.569ms 404
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[1]
Request starting HTTP/1.1 GET http://localhost:5000/
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[2]
Request finished in 0.4535ms 404
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[1]
Request starting HTTP/1.1 GET http://localhost:5000/home
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[2]
Request finished in 0.2ms 404
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[1]
Request starting HTTP/1.1 GET http://localhost:5000/
info: Microsoft.AspNetCore.Hosting.Internal.WebHost[2]
Request finished in 0.7621ms 404
then I open chrome and input "http://localhost:5000" ,the browser return "HTTP ERROR 404",
I don't know why, perhaps some of my operations are wrong?. please help, thank you!
@robertmuehsig commented on GitHub (Nov 4, 2017):
Mhh - do you have node.js installed? If yes, which version?
@niufwshd commented on GitHub (Nov 5, 2017):
@robertmuehsig ,thank you for your quickly answer first! yes node version 8.9.0 and npm version: 5.3.0
@robertmuehsig commented on GitHub (Nov 5, 2017):
Could you share our project on GitHub?
@GregorBiswanger commented on GitHub (Nov 6, 2017):
@niufwshd try to attach the process with visual studio and debug your startup code.. (See the steps on readme.md)
For debug startup code, you need currenty a Thread.Sleep() on begin the startup.
@GregorBiswanger commented on GitHub (Nov 10, 2017):
@niufwshd Did you find the problem?
@niufwshd commented on GitHub (Nov 12, 2017):
@robertmuehsig ,GregorBiswanger,sorry for my later reply. Today I saw https://www.youtube.com/watch?v=nuM6AojRFHk guide video. then I found my Fault. I am not very famailar with the .net core or my carelessness, In the program.cs I put this "UseElectron(args)" before "UseStartup()", and followed the Video, I switch their order,and execute dotnet restore, dotnet electronize init,and dotnet electronize start, at last I saw the miracle,desktop window appeared! very excited ! thank you very much!
@robertmuehsig commented on GitHub (Nov 12, 2017):
If you have any questions left, just open a new issue. The order is quite important - not only for Electron, but for other ASP.NET Core packages as well. Glad Gregors video helped!
@MADC0D3R commented on GitHub (Jan 28, 2019):
I'm running into a similar situation. I'm running VueJS on the client and .Net core as MVC. If I debug the hello world vueJS application runs in Chrome just fine, but when I run Electronize start I get an empty Electron.NET window. On further inspection (developer tools) I notice that I'm getting a 404 error when trying to navigate to my VueJS application.