CS0103 C# The name 'Json' does not exist in the current context

Question: How do you solve the error "The name 'Json' does not exist in the current context in Asp.Net 5 Web API.


Please Login to see the rest of the answer

Answer: Use ActionResult as a return type and not IActionResults. Make sure that your API Controller is inheriting from Controller and Not ControllerBase. Comment below if this helped you or if there is something we should help you with.

 


Write an Article
If you log in, you will be notified when someone leaves a comment.

Other users would like to know if this solution helped you.


© 2022 - ErnesTech - Privacy