Asp.net mvc ListBox recommendations? - asp.net-mvc

I'm converting a asp.net application over to asp.net mvc that uses a lot of listboxes, specifically the RadListBox from Telerik. The ListBox that comes with mvc is very basic and I'm wondering if anyone has come across a better alternative. I'm really looking for the ability to reorder, add, and delete from the client. Thanks

It seems at the moment there is no special tool (with professional features like Telerik tools) for MVC. However I suggest you using extension methods as it was my problem already:
And also you can replace it with a [Telerik MVC dropdownlist][2]
[2]: http://demos.telerik.com/aspnet-mvc/razor/combobox which is Free!

Related

ASP.Net MVC or Web forms which is better

I am going to start work on a SaaS based application. I need to decide whether to go with ASP.Net MVC or web forms application. Through various posts I came to know that both are good, they are not replacement of each other and so on.
Also, I know traditional web forms method, I am not aware of MVC, I need to learn it first.
Please guide me which approach is better.
Thanks,
Vijay
i can just share some of my experience as i have worked on both
i preffer asp.net MVC over Asp.net because of the futile layer of abstraction that Asp.Net has over basic HTTP architecture
the user controls in asp.Net induce unnecessary markup
ease of using ajax in asp.net mvc compared to updatepanel(in advanced senarious)
support of razor type syntax increases productivity
no overloading by things like viewstate
because everything is managed by the programmer soem of the typical issues that arise in asp.net like the problems in dynamic controls are no longer present
so if you ask me go for asp.net MVC
There is no right answer here. I prefer MVC but if you already know ASP.Net WebForms it probably is easier to stick with that.

Is ASP.NET MVC a good platform?

I aim to try use DevExpress web server controls (which are awesome) in an ASP.NET MVC project (some articles I read on 'net seems to indicate the two can work well together).
I'm eager to start a new project using ASP.NET MVC, and I have been reading up a lot on ASP.NET MVC lately, but I'm not sure if I should invest a project in it. My concern is that it may turn out to be like LINQ to SQL, which is essentially been killed off since MS will not be providing updates.
Is ASP.NET MVC a viable solution to invest in my case?
Yes definitely ASP.NET MVC or any other MVC framework is worth learning. MVC pattern is all about seperation of concerns and helps you to keep your code clean.
If you like Devexpress control too much you could be disappointed because there is no server side control in ASP.NET MVC. But if you want to learn Web's underlying mechanism,HTML, Javascript , clean code, TDD ASP.NET MVC is a good way to go.
Learn first, experiment later
Asp.net MVC is a great development platform for building web applications, so it's definitely worth your time to learn it through and through.
But I suggest you first learn MVC framework and build at least one semi complex app with it and then start experimenting with mixing MVC with web forms controls. It is possible but as much you think you will gain you'll probably loose more. So I would be a bit reluctant and advise you not to match these. At least not on a Greenfield project.
In other words: presumably knowing Asp.net web forms would you suggest someone to heavy use dynamicly created user controls in their web pages if they're just about to learn the technology of Asp.net web forms? Probably not. Or mixing web forms with ASP pages on a greenfield project...
Instead try finding great either MVC-friendly server extensions or client-side libraries that will help you create rich web apps like ExtJS (I don't work for ExtJS llc, but I used the lib on a project in the past and liked it a lot). Using something like this you won't loose stuff from MVC and gain great user experience and rich functionality.
Seeing how you're asking the question on this site, I'd say YES!
DevExpress has a bunch of MVC specialized controls, that use Ajax to get data from the server via callbacks. You can see demos of the controls here:
http://mvc.devexpress.com.
I am not sure if you can use the web forms controls, my understanding is that you can't.
Also, regarding LinqToSql, you don't have to use that. I am using NHibernate for the data layer and it works very nice with MVC.
I worked with asp.net and web forms for more than 5 years and at least 1 year with the DevExpress controls for asp.net, but now I love MVC so much that I think I don't want to go back to the web forms anytime soon.
Hope this helped.

Telerik controls in ASP.NET MVC

Telerik claims their controls work with ASP.NET MVC now. Has anyone already used the controls in a MVC project?
My company uses the Telerik ASP.NET controls in a large application and it works out quite well. That's why we think about using them in a MVC project.
EDIT 1:
telerik has a new go at ASP.NET MVC this looks much better then their first go at it. But it was to late for my project. http://www.telerik.com/products/aspnet-mvc.aspx
You could check out the demo application (a forums application) they built using ASP.NET MVC, announced here. Source code is available.
The demo is a simple- and stylish -
forums application. It uses 9 of the
RadControls, including RadGrid,
RadEditor, RadChart, RadTreeView and
RadUpload, to build a forum site that
has basic thread/post navigation,
formatted forum posting, user
authentication (with support for
custom avatars), and a site activity
"Statistics" view. Everything you need
to have a fully functional MVC forums
app. The source is available for
immediate download, so I encourage
anyone interested in learning more
about MVC or the RadControls in MVC to
grab the bites and study the example.
You may have already seen it, but Telerik has a blog post about how to use their controls with MVC and some of the limitations. I don't actually use their controls so I can't speak to whether the limitations are really a problem. It does appear that there is a a little more "manual lifting", so to speak, when using the controls with MVC but that there are workarounds to get most of them to work properly.
I'm hoping that they will eventually release MVC versions of their controls. I'm holding off evaluating them until that happens, but if you're already using them I'd certainly look to see how easy they would be to use with MVC. Perhaps you could update your question with an answer if you give it a try and let the rest of us know how it went.
I have been using the Telerik controls for about 6 months. I have been using the Grid and Window controls on MVC 2. Like most commercial products there are issues we have been fortunate to work them out. Once you get past the initial learning curve the controls are time savers. You can't beat the price for the amount of functionality you get.
My biggest issue is that they seem a bit sluggish responding on their forums. Maybe I'm just asking lame questions. I've been lobbying management to pay the $ for the supported version. Considering the amount of time we spend digging around to solve some of the more complicated problems I think it would be worth it.
I've just had a look at their grid and wrote a small POC project with it and must say I'm quite impressed. I'm not sure about their previous MVC controls iterations, but the current one can be a real time saver. It also fits very nicely into ASP.NET MVC ajax applications since there is a rich client-side API. Having jquery DataTables on the client side results in an even better user experience (because it is much faster), but also requires more error-prone javascript code.
As an alternative, you can check for MDBootstrap (it´s a front-end framework built on top of Bootstrap). There you will find an article with free ASP.NET MVC templates.

ASP.NET MVC & Expression XAML - How do I integrate?

Some Background:
ASP.net MVC is primarly a paradigm shift in the way you structure and develop ASP.NET applications. Shifting from a "code behind" type of mentality to more of a standard MVC Ruby on Rails like mentality. I applaud it's efforts as a simlifying tool towards unit testing ease and seperation of code (although the html inline code could be debatable).
Expression and XAML is a way to describe the presentation layer that can be simple for designers.
The question is:
If we are to use ASP.NET MVC in developing our next website how does the design team that uses Expression and XAML supposed to create (V)iews or integrate into the development flow?
More specifically can Expression users still operate in an ASP.NET MVC world?
Note that the pages in Expression's model use a code behind paradigm as well.
It is a hack, but you can use XAML to render static images in ASP.NET MVC. Check out my post XAML Meets ASP.NET MVC - Serverside Image Rendering - that shows how to render XAML and WPF controls as an image in ASP.NET MVC
http://amazedsaint.blogspot.com/2010/07/xaml-meets-aspnet-mvc-create-databound.html
There is also the MvcXaml project that is a View Engine that allows for images to be dynamically generated based on a XAML view.
http://mvcxaml.codeplex.com
I will try to answer this, making several assumptions that may be wrong.
ASP.Net MVC is a web technology and XAML is a desktop one. You can use XAML inside Internet Explorer, but it's basically a hack, it works best for desktop or silverlight applications.
If you want a paradigm similar to MVC for the desktop, you should try the M-V-VM pattern, who is more appropriate to WPF and XAML.
With M-V-VM you can create views almost code-behind free.
A great intro to M-V-VM is this video by Jason Dolinger
If you are making a website using MVC and you are trying to integrate the design team, you should let them create the HTML+CSS views of your site, while the developers create the controllers and the models.
Please comment in this answer if I have misinterpreted the question.
I'm currently banging my head on these terms. However, maybe this silverlight-as-a-view-in-aspnet-mvc article will help? You've asked about XAML, and I thing this is what Silverlight uses...

What is the best way to use MicrosoftReportView control in ASP.NET MVC framework?

Exactly same as the title of my question,
What is the best way to use MicrosoftReportView control in ASP.NET MVC framework?
I need to use report viewer control in asp.net mvc application, but I am so confused that how to use that control in mvc framework without violation of mvc pattern.
Thanks in advance.
You can mix both WebForms and MVC pages in the same application, so you may want to just develop a single WebForms page for the one that requires the ReportView. Hanselman describes a similar scenario on his blog. If you need it in an MVC page, you may want to look the following for hints on how to do so. I have no idea if this particular control will work or not, since I haven't tried this.
http://codebetter.com/blogs/david.hayden/archive/2007/12/27/asp-net-mvc-and-accessing-server-controls-in-codebehind.aspx
http://flux88.com/blog/leveraging-existing-asp-net-features-in-asp-net-mvc/

Resources