Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 510733
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T07:08:38+00:00 2026-05-13T07:08:38+00:00

In my view the call below generates url ending with Tasks/Edit but I want

  • 0

In my view the call below generates url ending with Tasks/Edit but I want it to generate url like Tasks/Edit/23

<%= Html.ActionLink<TaskController>("Edit Task", (x) => x.Edit("23"))%>

in Global.asax:

string taskController = NameResolver.NameOfController<TaskController>();
string editAction = NameResolver.NameOfAction<TaskController>(x => x.Edit(null));
routes.MapRoute(
       "EditTasks",
       "Tasks/Edit/{id}",
       new { controller = taskController, action = editAction, id = string.Empty });

I also have binding problem in this action. Values set from view is not binded to my Edit parameter. It comes null everytime and I have not set DefaultModelBinder anywhere. Here is the Edit action:

    public ActionResult Edit (string id)
    {
       //retrieve some data and pass it to view and return view
    }

So what can be the problem here? How can I solve url and binding problem? And yes I am a Asp.Net Mvc beginner 🙂

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T07:08:38+00:00Added an answer on May 13, 2026 at 7:08 am
    <%= Html.ActionLink("Task", "Edit", new { id = "2" }) %>
    

    Although why is your id a string and not an int?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'd like to create a custom view (I'll call it MyComplexView ), for example
I have two partial view and I want to call one of them in
I want to call a controller function from a view. Is that possible in
I use below code to open .doc file by call other application. But I
I need to call an ASPX page from MVC view through below JavaScript code,
I want to call system camera and take lots of photo in system view,
Stupid stupid question but here we are.. so, I want to generate some random
I'm trying to return a JSON response from a Django view call via an
I am developing an application that currently has a View Controller (call it ViewControllerX).
I implemented 4 views in AppDelegate depends on requirement it will call the view.I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.