blah blah blah is here! blah blah » Close

0
votes
0 answers

Is it bad practice to pass a model to the view that may have null vaues?

Rick_A
761

I have custom view models that I pass from my controller's action to the view. Is it bad practise to have properties on the model that are null? The values that are null are not accessed because I have a if statement to prevent access ...

0
votes
0 answers

Can I initialize an actions model from OnActionExecuted?

Rick_A
761

If all my actions pass a model to their respective views, is it possible for me to initialize the model from the pre-action filter OnActionExecuting? All my models inherit from 'MyBaseViewModel', does this make it possible to do this?

0
votes
0 answers

Is it possible to unit test a asp.net mvc view page? Specifically, testing helpers?

Rick_A
761

Many asp.net mvc view page helpers produce HTML output, and this output is dependent upon the routing information like controller and action naming. If I was to rename a controller, or an action, a form helper or link helper may break. i ...

0
votes
0 answers

How to pass a user controls view data from within a view page?

Rick_A
761

I have a view page that also renders a partial control (ascx). How do I pass the user control's model (view data)? I guess I have to initialize both models from the view page, and then pass the user control's model like that?

0
votes
0 answers

How to build Html helpers for asp.net mvc?

Is there any official documentation on best-practices on how to create reusable html helpers with ASP.NET MVC? I need these helpers to do things like: Display a boolean value that I get from the database and display it as a simple dro ...

0
votes
0 answers

Works locally, but deployment server says request does not match any route?

Locally my asp.net MVC application works fine. So I deployed the /bin folder, along with all the images, css, and javascript files. And ofcourse all my view pages (the entire /views folder). Web.config and default.aspx file. [code]S ...

1
votes
0 answers

Can you use MVC templates in webforms?

sanjib
226

Can I use an MVC template into my web forms? Can it done? Or since Model view Controler is a different concept, it will never work?

0
votes
1 answers

What is the difference between ASP.NET MVC and webforms?

Rick_A
761

It seems ASP.NET MVC is really taking off, I have read that it might not be the best route for every situation, but it does have its advantages over webforms. What are the main differences between ASP.NET MVC and webforms? Is it faster ...

Feedback