Using ReportViewe Control in asp.net mvc - asp.net-mvc

I'm asp.net mvc for my project and now I have to show a couple of reports using the ReportViewer control. I need to specify a couple of properties before rendering the report ie. ReportServer Url.
Is it possible to achieve this using asp.net mvc?

You can't use reportviewer control in asp.net mvc because it needs postbacks.
But you can use it to generate an image and show it (some googling should give you results about how to accomplish that).
Another option - you can make a hybrid application (web forms + mvc).
And another option - you can try javascript charts. Google charts looks good for example.

Related

add pagination control for asp.net mvc

I am new to asp.net MVC. I am trying to understand how to add pagination for a list of items using MVC without code for a view. I am using nunit testing to check whether pager option is tested or not
There is no built-in pagination for a vanilla MVC project -- you'll need to write one yourself or find something off the shelf.
See PagedList, which is also available on NuGet.

.net mvc template for events/arrangements with responsive design

I'm trying to find a good template for a event that my company is going to arrange.
The template I'm looking for have to be:
responsive design (focusing on mobile (iOS, Android and WP8)
calendar showing events, (showing only events in the future)
login
maps
Isn't there any template for events out there?
I've tried:
ASP.NET MVC 4 Bootstrap Layout template
HTML5 MVC4 Razor Responsive web template
Try this: https://wrapbootstrap.com/
I've already tried some templates there and they are very easy to implement. Maybe you'll need a combination of multiple templates.

DevExpress ASP.NET - Want to use Razor without MVC

I test the DevExpress (DX) ASP.NET
I want to make website with DX and Razor view.
When I create a new Web Project. I can choose between :
DXperience v12.2 ASP.NET Web Application
DXperience v12.2 ASP.NET MVC Web Application
In the choice 1, I can't choose the view language, Visual Studio create an ASPX website.
If I choose MVC, in the creation wizard, I can choose Razor or ASPX.
My question is can I create a website using Razor view without the MVC ?
I don't know the MVC pattern and be affraid to learn it now, I don't understand the logic inside it...
Depending on what you are specifically looking to do, you should check out RazorEngine - it lets you render HTML from Razor without alot of the scaffolding that you will have to do in order to use Razor like MVC uses Razor...

Side-by-Side Asp.Net and MVC Razor

We have an existing ASP.Net Web Application. I would like to create an ASP.Net MVC Razor Application where the two applications will work together. A single Master Page would contain menu items that can call .aspx pages as well as Razor .cshtml pages.
I have seen an example using MvcContrib Portable areas utilizing Routing. This particular example has .aspx pages in both (the MVC was not Razor).
Is there an example out there that will show the two running side-by-side and the MVC is Razor? It would be best if I could download a visual Studio Solution so that I can run this.
I am not sure if the MvcContrib way is the latest and best way to achieve this.
I do not want to go Hybrid!
You don't need any other external librarry. You can always convert the existing ASP.NET web forms Project to be a Hybrid one which uses webforms and MVC. You need to add the required MVC assembly references and make some changes to the web.config and you are all set. Scott has a simple and awesome blog post about this where he explains how to do the conversion.
I scribbled a note about how to enable the MVC specific Context menu( Add Controller / Add View) in the hybrid project after conversion here

Scheduler with asp.net MVC

I want to use a Scheduler like Telerik Scheduler in my MVC project. The problem is that the Scheduler is a Asp.Net WebForm control. For this reason, I must create a WebForm page in my Mvc project to put the Scheduler control.
When I show the page, it work fine to render the layout of the control but if I try to interact with it; click for change date, change to day view to week view, the control don't change.
I know that postback doesn't work in mvc project but does it work in a WebForm page in a Mvc project? If it doesn't work, it is the reason why when I try to interact with the control, the control don't respond.
I think it's because the postback don't work and the Scheduler use 100 % Databinding where when I change date, the postback don't contain any data that I have changed and for this reason, the control can't change is layout.
Do you have any ideas about postback with WebForm in a MVC project?
What type of designs can I adopt? (Two differents projets: One for my Scheduler with WebForm and another for all the rest of my website in Mvc project)
Are there any other controls that are easy to use with Scheduler?
Does anyone have any tips and tricks when needing both a WebForms control and MVC control in an MVC project?
Hanselman has a good guide for mixing MVC and WebForms into the same project.
You can try DayPilot Pro (my product, commercial) which has both ASP.NET and MVC versions.
ASP.NET:
http://www.daypilot.org/
MVC
http://mvc.daypilot.org/

Resources