i want to redirect to another action in same controller. how can we achieve this? i tried like return
RedirectToAction("NotAuthorized");
return RedirectToAction("ActionName");
Instead of return Redirect("/Elearning/NotAuthorized");
do this:
return RedirectToAction("NotAuthorized"); // if you're inside the Elearning controller
or
RedirectToAction("NotAuthorized", "Elearning"); // if calling from other controller
Try
return RedirectToAction("SomeAction");
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With