<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Andrey Shchekin's Blog - Latest Comments</title><link xmlns="http://www.w3.org/2005/Atom" rel="http://api.friendfeed.com/2008/03#sup" href="http://disqus.com/sup/all.sup#forumcomments-4801441f" type="application/json"/><link>http://ashmind.disqus.com/</link><description></description><atom:link href="http://ashmind.disqus.com/comments.rss" rel="self"></atom:link><language>en</language><lastBuildDate>Thu, 29 Dec 2011 07:38:49 -0000</lastBuildDate><item><title>Re: Comparing .NET DI (IoC) Frameworks, Part 1</title><link>http://blog.ashmind.com/index.php/2008/08/19/comparing-net-di-ioc-frameworks-part-1/#comment-396428120</link><description>Simple Injector is missing from the comparison. There's a answer on Stackoverflow that uses this article's feature list, to compare Simple Injector: &lt;a href="http://stackoverflow.com/a/8190700/264697" rel="nofollow"&gt;http://stackoverflow.com/a/819...&lt;/a&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Steven</dc:creator><pubDate>Thu, 29 Dec 2011 07:38:49 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-376206962</link><description>For anyone curious, I had a similar issue and the problem was in my Action.  I was using return View(model), so the server was looking for an "Action" view which really does not exist. The simple fix is to specifiy the view in the return:  return View("Edit", model).&lt;br&gt;&lt;br&gt;Thanks for this solution.  It has helped make a very nice Edit/Preview feature work efficently and cleanly.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">David Faucher</dc:creator><pubDate>Wed, 30 Nov 2011 15:51:05 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-372019506</link><description>Hello Andrey,&lt;br&gt;&lt;br&gt;If i left the Html.BeginForm() as default then irrespective of which button i click the actionName parameter is always the same, Ex: "delete", so my collection of buttons only behavior in the same way. If i left the Html.BeginForm("Action", "Post") as you used in this article then the IsValidName will always return false and no method at all will be executed. Am I missing on anything here?&lt;br&gt;&lt;br&gt;Regards,&lt;br&gt;Ambrish</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Ambrish</dc:creator><pubDate>Fri, 25 Nov 2011 05:28:39 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-369418731</link><description>Hi Diego,&lt;br&gt;&lt;br&gt;Can you please explain what was the mistake and what fix you had to do. I am facimg the same problem.&lt;br&gt;&lt;br&gt;Regards,&lt;br&gt;Ambrish</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Ambrish</dc:creator><pubDate>Mon, 21 Nov 2011 11:34:08 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-360351781</link><description>Hey Andrey,&lt;br&gt;&lt;br&gt;This solution is just excellent, very clean , much better then the proposed solution from David Findley&lt;br&gt;&lt;br&gt;I added some commenting and swapped the hard coded "Action" for a default, check it out:&lt;br&gt;&lt;a href="http://pastebin.com/PhnKDekw" rel="nofollow"&gt;http://pastebin.com/PhnKDekw&lt;/a&gt;&lt;br&gt;&lt;br&gt;I will be using this whenever i use multiple buttons, in other situations i usually just use jQuery Postback.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">willem dhaeseleer</dc:creator><pubDate>Thu, 10 Nov 2011 16:03:12 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-357393549</link><description>Hi,&lt;br&gt;&lt;br&gt;I can't really get it to work with JQuery, seems to be conflicting in some area. Any ideas?</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Richard Lim</dc:creator><pubDate>Mon, 07 Nov 2011 04:53:44 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-305371558</link><description>It depends on a mindset — if you are looking for a solution, yes, there are several ways to do this.&lt;br&gt;However I wanted to solve it in the way MVC framework has intended for controllers to be used — abstracted from the lowest details of HTTP (see Model Binders etc).</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andrey Shchekin</dc:creator><pubDate>Thu, 08 Sep 2011 18:44:21 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-305156269</link><description>this seems like a very complicated solution to a very simple issue. All you have to do is give each button a unique name, set the names as optional string parameters with default empty string values, then check if the parameters have a value.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">sarah perrie</dc:creator><pubDate>Thu, 08 Sep 2011 13:47:13 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-265482242</link><description>Very clean. I like it. Thanks for a great post.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">DGurram</dc:creator><pubDate>Tue, 26 Jul 2011 11:07:00 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-244786039</link><description>I am having the problem in passing an id to my action method. The id passed is null. I have read the comments in the blog but haven't found any solutions. Can anybody who previously faced the same problem help me</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Prateeksasanker</dc:creator><pubDate>Thu, 07 Jul 2011 04:59:22 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-200049124</link><description>Thats work fine.&lt;br&gt;But what if u use Ajax.BeginForm? can we have more than one actionmethod?</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Garry</dc:creator><pubDate>Mon, 09 May 2011 05:20:03 -0000</pubDate></item><item><title>Re: Comparing .NET DI (IoC) Frameworks, Part 2</title><link>http://blog.ashmind.com/index.php/2008/09/08/comparing-net-di-ioc-frameworks-part-2/#comment-198253431</link><description>Great article. But a bit dated. A update will do a lot of good.&lt;br&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Naser</dc:creator><pubDate>Fri, 06 May 2011 06:51:25 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-178513933</link><description>Very useful, thanks.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jackandjane</dc:creator><pubDate>Tue, 05 Apr 2011 10:38:32 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-148162327</link><description>Ahhhh, ok, that makes perfect sense now, I'm so used to strongly typed views being a requirement due to the fact that it's required in all of our designs at work.  Great post, I'll see if I can come up with an implementation using strongly typed views.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">teachM3</dc:creator><pubDate>Tue, 15 Feb 2011 23:21:25 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-147838331</link><description>That's weird. Can you look at what exactly gets submitted? (using Firebug, for example)</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andrey Shchekin</dc:creator><pubDate>Tue, 15 Feb 2011 16:47:17 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-147837739</link><description>Yes, I agree, and I should probably create a separate class for the name.&lt;br&gt;But I am a bit too lazy right now to update the post, so I'll leave it for now with only a demonstration of more complex part.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andrey Shchekin</dc:creator><pubDate>Tue, 15 Feb 2011 16:46:30 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-147835287</link><description>Well the actions are not strongly typed when used this way.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andrey Shchekin</dc:creator><pubDate>Tue, 15 Feb 2011 16:43:30 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-147822315</link><description>I haven't yet had time to look into it since I do not have image buttons, sorry.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andrey Shchekin</dc:creator><pubDate>Tue, 15 Feb 2011 16:27:57 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-147818948</link><description>Maybe I'm completely missing something here, but if you don't provide an action with the Name of "Action" in your Post controller, how does the view even compile?</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">teachM3</dc:creator><pubDate>Tue, 15 Feb 2011 16:24:18 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-147732822</link><description>Great post!&lt;br&gt;&lt;br&gt;As for your last statement of: There is some room for improvements (hardcoded “action” as a default action name), but in general I’m satisfied with this solution.&lt;br&gt;How about adding a static read only property to the attribute?&lt;br&gt;i.e.&lt;br&gt;public class HttpParamActionAttribute : ActionNameSelectorAttribute&lt;br&gt;{&lt;br&gt;... existing code here ... with one change&lt;br&gt;if (!actionName.Equals(ActionName (&amp;lt;-- referencing the property so there's only one place to change the action name)&lt;br&gt;&lt;br&gt;	/// &amp;lt;summary&amp;gt;&lt;br&gt;	/// Gets the name of the action for the Html.BeginForm to allow multiple submit buttons to invoke specific action methods in ASP.NET MVC.&lt;br&gt;	/// &lt;code&gt;&lt;br&gt;	/// using (Html.BeginForm(HttpParamActionAttribute.ActionName, "Controller Name Here")) {&lt;br&gt;	/// &amp;lt;button type="submit" name="ActualActionName"&amp;gt;Save&amp;lt;/button&amp;gt;&lt;br&gt;	/// }&lt;br&gt;	/// &lt;/code&gt;&lt;br&gt;	/// &amp;lt;/summary&amp;gt;&lt;br&gt;	/// &amp;lt;value&amp;gt;&lt;br&gt;	/// The name of the action.&lt;br&gt;	/// &amp;lt;/value&amp;gt;&lt;br&gt;	public static string ActionName&lt;br&gt;	{&lt;br&gt;		get { return "MultipleSubmitButtons"; }&lt;br&gt;	}&lt;br&gt;}&lt;br&gt;&lt;br&gt;and the begin form looking like:&lt;br&gt;using (Html.BeginForm(HttpParamActionAttribute.ActionName, "Post")&lt;br&gt;&lt;br&gt;If you don't care for the ActionName property being in the actual attribute, you could create a new class both the attribute and BeginForm method can use...</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Werewolf</dc:creator><pubDate>Tue, 15 Feb 2011 14:51:46 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-143755301</link><description>Correction partial view not partial class.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">AEL</dc:creator><pubDate>Wed, 09 Feb 2011 19:16:19 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-143752436</link><description>Hi, thanks for this blog however this won't work for the buttons in the partial class.&lt;br&gt;&lt;br&gt;Here's the code snippet when calling the partial class:&lt;br&gt;asp:Content ID="Content2" ContentPlaceHolderID="PageContent" runat="server"&amp;gt;&lt;br&gt;&amp;lt;%Html.RenderAction("PartialView"); %&amp;gt;&lt;br&gt;&lt;br&gt;&amp;lt;%&lt;br&gt;       using (Html.BeginForm("Action", "Post", new { index =ViewData["index"] ))&lt;br&gt;       { %&amp;gt;&lt;br&gt;&lt;br&gt;Please advice.&lt;br&gt;&lt;br&gt;Thanks,&lt;br&gt;AEL&lt;br&gt;&lt;br&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">AEL</dc:creator><pubDate>Wed, 09 Feb 2011 19:09:03 -0000</pubDate></item><item><title>Re: Multiple submit buttons with ASP.NET MVC: final solution</title><link>http://blog.ashmind.com/index.php/2010/03/15/multiple-submit-buttons-with-asp-net-mvc-final-solution/#comment-116333188</link><description>[AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)]         //---You Forget it !!!&lt;br&gt;public class HttpParamActionAttribute : ActionNameSelectorAttribute {&lt;br&gt;...&lt;br&gt;}&lt;br&gt;&lt;br&gt;Sebastian.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Sebastian</dc:creator><pubDate>Tue, 21 Dec 2010 14:42:51 -0000</pubDate></item><item><title>Re: Comparing .NET DI (IoC) Frameworks, Part 2</title><link>http://blog.ashmind.com/index.php/2008/09/08/comparing-net-di-ioc-frameworks-part-2/#comment-115668092</link><description>If curious about the performance of some of the most popular IOC containers take a look &lt;a href="http://www.iocbattle.com" rel="nofollow"&gt;www.iocbattle.com&lt;/a&gt;.&lt;br&gt;Dynamo included is my own project to test how fast it is possible to go.</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Martin</dc:creator><pubDate>Mon, 20 Dec 2010 22:44:33 -0000</pubDate></item><item><title>Re: .NET DI (IoC) Frameworks, Revisited</title><link>http://blog.ashmind.com/index.php/2009/10/12/net-di-ioc-frameworks-revisited/#comment-115666636</link><description>If curious about the performance of some of the most popular IOC containers take a look &lt;a href="http://www.iocbattle.com" rel="nofollow"&gt;www.iocbattle.com&lt;/a&gt;.&lt;br&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Martin</dc:creator><pubDate>Mon, 20 Dec 2010 22:42:45 -0000</pubDate></item></channel></rss>
