mithu

Stories submitted by mithu

Meet my new ASP.NET MVC Extension - System.Web.Mvc-Kazi Manzur Rashid(weblogs.asp.net)

submitted by mithumithu(570) 2 years, 5 months ago

After hearing Phil Haack and Scott Hanselman in their latest podcast and PDC session I decided to give a good look at the MvcTrubine project in this weekend. I totally agree the intend of this project, let your favorite IoC to rule everywhere, but I do not think it has been implemented in the correct way. There are three important design flaws that I found in MvcTurbine: Generic Component Registration API Rather than allowing you to use your preferred IoC registration features, it prefers to use its own generic syntax for component registration, which is simply wrong. In real application, we need more support from our IoC such as lifetime management, auto wiring, modularity like (Ninject/Autfac Modules, StructureMap Registry) etc. In case of this generic API we have to throw away the features of these IoCs. Missing Common Service Locator I think the Common Service Locator(CSL) has become the standard to abstract the underlying IoC from your application code and all the popular IoCs in .NET world has an adapter for CSL. But rather than using/extending it, it has its own version of service locator. Limited support for Action Filter injection It uses a host kinda Attribute to inject the dependencies into the actual action filter attribute and this host is not capable of passing the attribute specific values to the actual attribute and even if this feature is implemented in the future it will be based upon the string based property name which would work on top of reflection. Now, lets see how my new extension solves the above issues and how easily you can start plugging it in your application. First lets take a quick look of the project structure of this extension. read more...

4 comments |category: |Views: 247

tags: another

Telerik ASP.NET MVC Grid Preview (Take 2) - Kazi Manzur Rashid(weblogs.asp.net)

submitted by mithumithu(570) 2 years, 5 months ago

In the last post, I have shown you how you can extend the ASP.NET MVC2 templates and some of the issues of the current beta. In this post, I will show you how we are taking advantages of the new DisplayFor/EditorFor in our MVC Grid. One of the benefit of using those statements in our grid is, you can host any kind of component in an individual cell, obviously the first two components will be the DateTimePicker and NumericTextBox that we are going to include in our next release. One of the most requested feature since our last release is the inline editing support in the grid. In this, I will show you the inline editing of product of my last post, but this time with our Grid. The Grid should support both server and ajax editing, but in this example we will only discuss the server..... read more...

1 comment |category: |Views: 282

tags: another

Extending ASP.NET MVC 2 Templates - Kazi Manzur Rashid(weblogs.asp.net)

submitted by mithumithu(570) 2 years, 6 months ago

One of the new features of ASP.NET MVC 2 is Templates (DisplayFor/EditorFor), Brad Wilson did a series of post which explains how the templates works, Please read it before you continue this post. Although he did an excellent job explaining the inner-details, but one thing you will notice that the object model in those examples are traversed from top to bottom or parent to child which is good for explaining the internal, but in our real application we need a bit more support. Lets take a trivial example, you are creating a create/edit screen for your Product, where each product has a associated Category and you want to show this category in a DropDownList, say we have a Product class like the.... read more...

add a comment |category: |Views: 207

tags: another

ASP.NET MVC View and Transaction - Kazi Manzur Rashid's(weblogs.asp.net)

submitted by mithumithu(570) 2 years, 6 months ago

Scott showed how to render the Grid in a Transaction. Certainly it does the job but in my opinion view component should not be responsible for this kind of cross cutting concerns, instead we can use the Action Filters. Lets see how we can utilize the Action Filter in this scenario instead of modifying the Grid code. What Scott is trying to do is encapsulate the data access operation in a transaction, the Action Filter has several methods which the ASP.NET MVC framework executes in different stages of a request. In this case, we will use the OnActionExecuting which fires before the code enters into the controller method to start a transaction and OnResultExecuted which fires when the view is processed, we will commit/rollback based upon the status, here is the code that would process the action result in a transaction: read more...

add a comment |category: |Views: 273

tags: another

ASP.NET MVC – Poll Result, jQuery UI MVC Component Demo and More Fe...(weblogs.asp.net)

submitted by mithumithu(570) 3 years ago

Few days back I ran a Poll to gather the feedback on ASP.NET MVC View Components that I am planning to build building. Though it is certainly not possible to get everyone’s vote of the ASP.NET MVC Community, but I think the result has enough votes to represents the whole community: read more...

1 comment |category: |Views: 370

tags: another

ASP.NET MVC – Poll Time - Kazi Manzur Rashid's Blog(weblogs.asp.net)

submitted by mithumithu(570) 3 years ago

Justin Etheredge recently wrote about the RAD support that he would like to see in ASP.NET MVC and I do agree with him very much (as a side note, I highly recommend his blog you should subscribe). I am also planning to create some reusable UI components for ASP.NET MVC and I need your feedback prior starting it. read more...

add a comment |category: |Views: 242

tags: another

KiGG is now upgraded to ASP.NET MVC RTM 1.0 - Kazi Manzur Rashid Blog(weblogs.asp.net)

submitted by mithumithu(570) 3 years, 1 month ago

Just to let you know that I have uploaded the latest source of KiGG in Codeplex. Other than upgrading to ASP.NET MVC RTM, there are few enhancements: 1. Implementing EventAggregator. 2. Background Services like: * Broadcast in Twitter. * Ping different Feed Servers automatically. 3. Restrict Story submit from specific domains. 4. SQL Server Full Text search. 5. Other minor enhancements and bug fixes. And yes http://dotnetshoutout.com is currently running the same codebase. Those who are assuming whether KiGG is following the same practices which I have mentioned recently over here and here, let me tell you, no it is not following all the items, I am in a process of refactoring it following those rest of the items which I hope to deliver in a few weeks or I will post the tiny app that I am also developing. read more...

add a comment |category: |Views: 14

tags: another

ASP.NET MVC Best Practices (Part 2) - Kazi Manzur Rashid's Blog(weblogs.asp.net)

submitted by mithumithu(570) 3 years, 1 month ago

This is the second part of the series and may be the last, till I find some thing new. My plan was to start with routing, controller, controller to model, controller to view and last of all the view, but some how I missed one important thing in routing, so I will begin with that in this post. read more...

add a comment |category: |Views: 433

tags: another

ASP.NET MVC Best Practices (Part 1) - Kazi Manzur Rashid's Blog(weblogs.asp.net)

submitted by mithumithu(570) 3 years, 1 month ago

In this post, I will share some of the best practices/guideline in developing ASP.NET MVC applications which I have learned in the hard way. I will not tell you to use DI or Unit Test instead I will assume you are already doing it and you prefer craftsmanship over anything. read more...

add a comment |category: |Views: 386

tags: another

Submitting my first bug after ASP.NET MVC 1.0 RTM Release - Kazi Manzu(weblogs.asp.net)

submitted by mithumithu(570) 3 years, 2 months ago

The Controller class of ASP.NET MVC Framework has few overloaded methods to return json result from the controller actions. Internally it uses the JavaScriptSerializer which was introduced in ASP.NET AJAX Framework. But unlike the DataContractJsonSerializer which works on attributes, the only way you can control the json output in JavaScriptSerializer class is by registering the JavaScriptConverter classes. In most of the cases you don’t have to control the way the json data is shaping, but in some situation you might need to step in. If you check the overloaded Json methods, none of it takes the JavaScriptConverters as argument. read more...

add a comment |category: |Views: 23

tags: another