Navigate to MediatR handler in Visual Studio 2019 (or perhaps Rider) - visual-studio-2019

Im currently in a project that uses mediatR quite alot. I have a problem following the code. Currently I Search for "IRequestHandler<RequestObject", which feels a bit medieval
Is there any way to for example navigate to (or peek) the handler(s) of a mediator.Send(request) in Visual Studio 2019?
(any way in Jetbrains Rider?)

Both ReSharper and Rider can help you here.
Place the cursor on the RequestObject and then call:
In Rider: Navigate | Navigate To | Consuming APIs action
In Visual Studio: ReSharper | Navigate | Navigate To | Consuming APIs action
Visit this page to learn more about the Consuming APIs feature.

Related

Why isn't F# Interactive displaying line of code after "send selection to F# Interactive" is clicked?

I am new to F# and Visual Studio. I am following the F# tutorial provided by Visual Studio and the project runs fine, but whenever I try to highlight a line of code and perform "Send selection to F# Interactive" the window pulls up but nothing displays. I also do not have the ability to perform any actions in F# Interactive. Some background info:
I'm using a 2020 MacBook Pro and 2019 Visual Studio
I had previously installed Rider for class but then my professor switched to Visual Studio, not sure if having both installed causes a conflict?
Below is a video showing the VS tutorial file I'm working in and some of the problems I'm experiencing.
https://youtu.be/2hdBlm-h2i4
I appreciate any help as I have to keep using Visual Studio, F#, and F# Interactive for class and do not want to fall behind, thank you!

How to create Console App for ASP.NET Core in Visual Studio For Mac

I don't see an equivalent way to create a console app in Visual Studio for the Mac. That is, the equivalent of
dotnet new console
When I want asp.net core does not seem to show up as an option. I'm assuming I've missed it since it's kind of a basic thing.
Thanks
In Visual Studio for Mac you can use the File | New Solution... menu and within the dialog that shows up, select the .NET Core | App category on the side. Then you'll see the option to create a Console Application.

visual studio 2015 editor vs visual studio code for angular 4

I have created data access layer ,Business access layer and web api as separate projects in one visual studio solution.
I am trying to implement angular 4 project using angular cli. Is it better for me to include angular 4 as a class library project and add to the existing solution or do I avoid adding it to the solution and just use visual studio code to open it.
I need to know which is the better code editor to use as far as angular 4 is concerned.
I would argue that nowadays both VS Code and Visual Studio 2017 offer similar experiences. You can check my blog post here for more information:
https://blogs.msdn.microsoft.com/wael-kdouh/2017/09/05/should-i-use-visual-studio-2017-or-vs-code-for-my-next-angular-application/
If you want to successfully use the Angular CLI, the VS Code would be much easier than trying to merge the result into a Visual Studio project.
Alternatively, you can use the new dotnet new angular and use Visual Studio's template. See this link for more information: https://dotnetcore.gaprogman.com/2017/04/20/dotnet-new-angular-single-page-application-setup-and-how-the-template-works/
Most devs I know are going with option 1 and using the CLI and VS Code for the Angular piece and Visual Studio for the back-end piece.

Visual Studio 2015 "Not Responding" when adding an MVC controller or view

We are attempting to add MVC to an old, large, legacy webforms app. (The intent is to gradually re-implement portions of the app using MVC until the old app is gone).
Setting it up has gone smoothly. We have an MVC Area, and I created a controller which is accessible when running the app, by means on directly typing the url.
But whenever we "Add > Controller" or "Add > View"... Visual Studio hangs for around 10 minutes "Not Responding".
Clearly there is some bug in visual studio interacting with some quirk in our legacy project.
Googling, I have so far found only a few similar cases that are old & do not seem applicable.
Not sure where to begin resolving this.
UPDATE:
For what it is worth, we have converted the original VB webforms project to C#. I then added MVC Nuget package and and MVC area. Visual studio no longer seems to hang when adding controllers. So this might be a VB specific thing. Or maybe some windows update to visual studio fixed this in the interim since i posted this. Not sure.
The problem is still present in Visual Studio 2015 Update 1.
As a workaround, instead of selecting "Add View" you can select "New Item" and choose a page template from Web/MVC instead.
It is still in Visual Studio 2017; It takes time and you can restart making Controller/View or you can wait sometimes
this seems like bugs from visual studio,
you can copy other controller and paste it then rename namespace.
for temporary until visual studio is fixed.
I'm having the same issue. This should work. I'm selecting "Add Controller" from the context menu. It just spins saying Visual Studio not responding. This is with Visual Studio 2015.
In my case this situation arises when adding view to the controller and visual studio 2015 hangs indefinitely. However it creates the view file in the directory but not shown in solution explorer. I have manually copy pasted the file from directory to solution explorer and everything worked well.
Check if the below blog could help resolve your issue
http://digioz.blogspot.co.uk/2013/06/visual-studio-2012-freezes-or-crashes.html

Asp.net mvc in MS Expression Web (and other web editing tools)

Today I gave in to all the banners asking me to test MS Expression web 2 demo.
After some setup hickups I fired up the thing and immediately encountered a problem:
How do I make this tool work with my asp.net-mvc projects? Actually, how do I make my websites work with ANY tool but visual studio 2008?
Untill now I did everything with VS2008 / Notepad++.
Does anybody have experience with using asp.net-mvc projects in tools like dreamweaver, expression web etc?
You can use any web tool to edit the HTML+CSS+Javascript side of the site, but you'll need to compile it with VS2008 or MSBuild to run it.

Resources