How to use ActionResult and IActionResult for ASP.NET Web API

preview_player
Показать описание
#csharp #csharp11 #dotnet #dotnet7 #webapi

When multiple return types are possible, that is when we use an IActionResult or ActionResult return type.

00:00 - Introduction
00:50 - Use case for the need for IActionResult
01:50 - When to use IActionResult or ActionResult
02:10 - Usage of IActionResult
03:40 - How to make swagger documentation to show schema
05:26 - Usage of ActionResult
06:35 - Different type of action result for IActionResult
07:20 - Usage of Created action result
09:12 - Conclusion

Some of my popular videos:

Рекомендации по теме
Комментарии
Автор

Is there any differences if I put the return type as IActionResult vs ActionResult (Not ActionResult<T>) without specifying the object?

faizshaari
Автор

I wonder what is the difference between IActionResult and ActionResult only without specifying the generic type?

kriskata
Автор

Can you tell if there was inactionresult, then why we need actionresult

shourjyajitmaiti
Автор

Hello sir,
Make videos on dsa please

utkarshkumar