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 1107931
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T02:00:23+00:00 2026-05-17T02:00:23+00:00

link text I am following the answer in this link, I have done this…

  • 0

link text

I am following the answer in this link, I have done this…

<% Html.BeginForm("MyAction", "MyController", FormMethod.Post); %>
  <input type="submit" name="submitButton" value="Send" />
  <input type="submit" name="submitButton" value="Cancel" />
<% Html.EndForm(); %>

<% Html.BeginForm("Send", "MyController", FormMethod.Post); %>
  <input type="submit" name="button" value="Send" />
<% Html.EndForm(); %>

<% Html.BeginForm("Cancel", "MyController", FormMethod.Post); %>
  <input type="submit" name="button" value="Cancel" />
<% Html.EndForm(); %>

With this in the controller…

public class MyController : Controller {
public ActionResult MyAction(string submitButton) {
    switch(submitButton) {
        case "Send":
            // delegate sending to another controller action
            return(Send());
        case "Cancel":
            // call another action to perform the cancellation
            return(Cancel());
        default:
            // If they've submitted the form without a submitButton, 
            // just return the view again.
            return(View());
    }
}

private ActionResult Cancel() {
    // process the cancellation request here.
    return(View("Cancelled"));
}

private ActionResult Send() {
    // perform the actual send operation here.
    return(View("SendConfirmed"));
}

}

But I keep getting a Resource not found error – Cannot find MyController\MyAction

  • 1 1 Answer
  • 2 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-17T02:00:23+00:00Added an answer on May 17, 2026 at 2:00 am

    Don’t specify “Controller” in the Form parameter:

    <% Html.BeginForm("MyAction", "My", FormMethod.Post); %>
      <input type="submit" name="submitButton" value="Send" />
      <input type="submit" name="submitButton" value="Cancel" />
    <% Html.EndForm(); %>
    

    Link will be /My/MyAction if you want it to be MyController, the Controller class must be called MyControllerController (not tested though)

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

Sidebar

Related Questions

I have the following HTML <p>Some text <a title=link href=http://link.com/ target=_blank>my link</a> more text
I have the following Javascript to make a text link glow/pulsate continuously. This link
In my Rails project I have the following code: auto_link( h( wrap_long_string(post.text,50) )).gsub(/\n/,<br />)
i need to create a chart similar to this: link text Do you have
Following on from my previous question [link text][1] , I have a new problem.
I have added an CSS file this way: <link rel=stylesheet href=style.css type=text/css media=screen, print>
currently I have following code: home.php <form name='myformname' id='myformid'> <input type='text' name='mytext1' value='abc'> <input
I have the following code browser.link(:text => 'Generate Report').click browser.radio(:value => 'byTotalValue').wait_until_present(180) which requests
I have the following ActionLink in my view <%= Html.ActionLink(LinkText, Action, Controller); %> and
i have one domain link text i want to know that does google crawl

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.