How to access to the 'Index' Action without write it after slash
Hello dear friends,
I'm working on
Asp.Net Core 6
project with Areas
,
I have a problem with routing
to the index
action.
The problem:
Let's assume that I have a Controller
called SchoolSubjectController
, and it contains an Action result
called Index
.
Above the Controller
I apply a set of Attributes
as shown bellow
From the browser when I try to access to the Index
action I should write .../Admin/SchoolSubject/Index
.
The question:
Please is there any method to let the Index
action is the default to show when I access to .../Admin/SchoolSubject
, in other means how to access to that Index
Action without write it after the controller's name in route ?
Massive thanks in advance.5 Replies
Unknown User•3y ago
Message Not Public
Sign In & Join Server To View
above the
Index
?Or don't include the action in the controller route
Unknown User•3y ago
Message Not Public
Sign In & Join Server To View
I tried this but didn't work
But when I tried this
It works