I have downloaded the Swagger-Net code from the Github respository(https://github.com/heldersepu/Swagger-Net)
Then i have open the solution in visualstudio and builded the code and executed the code.The server is starting but the swagger-ui is not loading on the browser after entering URL
The router works perfectly but UI is not rendering
I have gone through the browser console i am getting following error
1.faild to load swagger-ui-standalone-preset-js
2.faild to load swagger-ui-css
3.faild to load swagger-ui-bundle-js
Because i need to modify the code for my project requirement on the swagger-net
Kindly help how to setup the workable environment
MY CODE AVAILABLE IN "https://github.com/mydeenali/Share"
Related
My web application runs perfectly fine in Windows. I even have it running in production on a Linux server for years without issue.
Now that I try to open the solution on a Linux desktop with JetBrains Rider IDE, the project fails to load at all. I boot up the Windows VM and the very same project runs.
First of all, what is to blame, JetBrains Rider, ASP.NET, or my installation? I've been developing desktop apps without any issue.
I created a new web application to see whether ASP.NET runs and it does. I started copying everything over file by file.
I got Pages/Shared/Components that contains ProductBox.cs and ProductBoxModel.cs and it runs fine. I add the file Pages/Shared/Components/ProductBox/Default.cshtml and it fails to load. There is no error or anything.
Running it simply opens a blank page in Firefox. In Chrome, it will give a 404 error after a security warning. I delete that one specific file and the application starts again.
I found this issue: View Component Loading Issue on Production ASP.NET Core
Moved Pages/Shared/Components/ to Views/Shared/Components. The problem persists.
The View Component breaks the application in Linux, even if the View Component is not being reference at all.
How can I solve this? (other than opening it in Windows)
I got .NET 6 installed, and I'm testing this from a clean project created from template.
OS: Garuda Linux (arch-based)
IDE: JetBrains Rider
Components/ProductBox.cs contains
public class ProductBox : ViewComponent
{
public IViewComponentResult Invoke() => View();
}
Components/ProductBox/Default.cshtml is completely empty
After flipping back-and-forth between the base project, a first blank project template with files copied over, and a 2nd blank project with files copied over... the View Component started to work somewhere along the lines. Got no clue where. There'sFOUND THE PROBLEM after having another problem preventing from bootingpushing the main project in Linux thoughbuild to production.
But then WebApplication1 would boot with all the same times. Started paying attention to any hidden files, likeIn Properties/launchSettingsappsettings.json. In the end; The entire application runs in WebApplication1 with all the same files, and original one still doesn't run, even after deleting obj/bin folders. Just renamed WebApplication1 to the main project name
I was facing 2 problems though. One with View Components giving a blank page, and one with failed connection.
Found the 2nd problem after having another problem pushing the build to production.
In appsettings.json
"Kestrel": {
"EndPoints": {
"Http": {
"Url": "http://localhost:5003"
}
}
}
If that configuration is present, it works in Visual Studio but fails in JetBrains Rider!
Without it; it fails to run on the server.
The solution is to move it to appsettings.Production.json.
I'm having an error
"Could not load type 'MyNameSpace.MvcApplication' (source file
global.asax) when trying to browse app on IIS 7.5.
I tried many solutions on other threads i searched before asking my question but with no success.
several things I have noticed so far:
1) If I open the solution on visual studio and run the app from in it (on local host) the app runs without the error.
2) On the IIS I have two sites (default and another one) and if I make the app on the default site it runs perfectly but if I make the app on the second site (withto the same solution folder) I encountered this error.
I tried to look on all the configurations but it looks the same on both sites.
I'm not very familiar with IIS and I would thank you very much for any help.
You usually get this error when you request an ASPX file (which is the default in VS if you have focus in an aspx file). MVC URLs are to action methods, not files. Set default.aspx as your start up file.
I compiled the cefsharp and did a setup file from it. I installed the my custom browser on my windows 7 64 bit pc and I made my custom browser, the default browser. There is not problem until here. It runs perfectly when I run the browser.exe.
Problem is:
When I clicked a local html file or a link like that this picture(), The browser.exe run but cannot open, returns error. Error is "It cannot load cefsharp.dll, cefshap.core.dll ..., all cefsharp dlls"
How can I solve this?
Cefsharp has a bug in Cefsharp.dll while loading the dependencies. I fixed it and error gone.
While loading the dependencies some paths are absoulate. I change them into relative paths.
first of all I'm a total newbie with Asp.net. On the other hand I use C# everyday.
So what I have to do is a fairly easy matter except for the fact that I don't know Asp.Net.
I am require to make a simple form that gathers data in a Sqlite database.
I am using VS2008 and the latest version of Sqlite.
Everything works fine when working locally (I can run the website and add data to the s3db db).
The problems are coming out when it comes to publishing. At the moment I am publishing ON MY FILE SYSTEM accordin to procedure Walkthrough: Deploying a Web Site Project by Using the Publish Web Site Tool
so when it comes to the paragraph Testing the published Website (published in the folder C:\CompiledWebSite so the local address is http://localhost/CompiledSite/Default.aspx) I get the error:
Server Error in '/CompiledSite' Application.
Could not load file or assembly 'System.Data.SQLite' or one of its dependencies. An attempt was made to load a program with an incorrect format.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.BadImageFormatException: Could not load file or assembly 'System.Data.SQLite' or one of its dependencies. An attempt was made to load a program with an incorrect format.
which I didn't get when running it from VS2008.
So all what comes to my mind is that it's not a matter of Sqlite format but a problem related to the fact that it doesn't find the .s3db file which in the end there isn't in the folder C:\CompiledSite.
But I added it to the solution! And I can see it in the solution explorer structure.
I think that all problems come from my being totally unaware of how asp works but I have to find a solution!
can anybody help me?
thanx in advance!
I found it!!!
from
http://www.codeproject.com/Articles/548421/Anplusattemptpluswasplusmadeplustoplusloadplusaplu
it says to go to IIS and set Application Pools --> Advanced Settings --> Set "Enabled 32-Bit Application" to True and press OK
that worked!!
I created a web site with .NET 4.0 . I published it to my server's IIS. My web site is working. But after publish when i tried to add new forms they work on Visual Studio's localhost but doesn't work on IIS . For example I create etik.aspx . It works on Visual Studio but when I deploy it to IIS It gives me this error.
Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.
Parser Error Message: Could not load type 'BerksanWebSite.berknet.etik'.
Something else I add a change to my master page. It shows front changes (on aspx file) but changes in aspx.cs file doesn't work . I don't understand why it is not working. Can anybody help me?
Start from searching similar topics with same message
Parser Error when deploy ASP.NET application
Try to push back your changes and find which one cause error.
May be find a video tutorial. Try again for empty project and simple form.
I solved this problem with uploading new bin files to server. Thanks #Eldar