My controllers are utilizing StructureMap and AutoMapper. Presently, there is nothing exceptional with my routes. For the basic CRUD controller actions what tests should I be writing to ensure good code coverage?
...
Hey all,
I'm in part four of the MvcMusicStore tutorial.
I just finished creating my Edit template view and putting it in the Views/Shared folder. The problem is I can't figure out how to make it work.
My controller action is:
public ActionResult Edit(int id)
{
var viewModel = new StoreManagerViewModel
{
Album = store...
I'm new to ASP.NET MVC. I've seen both <%= ... %> and <%: ... %>. I'm familiar with the first from classic ASP days, but not the latter. What is the difference between the two?
...
Hi there,
i was wondering if there is a way to use ASP.Net's Data annotation without the MVC site.
My example is that i have a class that once created needs to be validated, or will throw an error. I like the data annotations method, instead of a bunch of if blocks fired by the initaliser.
Is there a way to get this to work?
I though...
So I have a masterpage that has an image whos source is a controller action returning a filestream.
The image will be different for each logged in user.
right now in my masterpage view i have this code wich relies on viewdata.
<img id="dealerlogo" src='/Files/DealerImage/GetDealerLogo/<%=Html.Encode(ViewData["dealerid"]) %>' alt="" ...
Hi All,
Is there any option to disable the Export to Microsoft Excel menu in the IE browser right click.
I tried the web.config method and also changing the system registry using regedit.exe
As i want this menu to be disabled to users who are accessing my application.
...
If I have a dbml file that contains say a Customer class with say a single property of CompanyName;
public partial class Customer : INotifyPropertyChanging, INotifyPropertyChanged
private string _CompanyName;
public string CompanyName
{
get
Now, given that the above is in a dbml and thus generated I obviously should avoid editing it...
I've got a weird error in a couple MVC apps that I've not noticed before; it's happening in my app (across the board) and also it happened when I tried running the latest Orchard drop (so I know it's not just my code).
Basically, the issue is that I get the exception that should be thrown when an AntiforgeryToken isn't supplied, but is ...
Which are the similar features and differences between ASP MVC and RubyonRails?
...
Do you think that ASP.NET MVC is an Agile technology? Which features make it Agile?
...
I googled for twitter like alert but all the articles were in php... Is there an asp.net mvc one out there? Here is the http://briancray.com/2009/05/06/twitter-style-alert-jquery-cs-php/ sample in php..
...
HI
I am using telerik mvc grid with ajax binding
<%Html.Telerik().Grid<UserManagement.Models.setupEmployee>()
.Name("setupEmployees")
.DataBinding(dataBinding => dataBinding
//Ajax binding
.Ajax()
//The action method which will return JSON
.Sel...
Hi, I have a beginner level Json question with MVC.net (I've never really used jquery or json) so please excuse me if I ask something stupid.
I have a javascript file with the below
<script>
function refreshMovies() {
//$.getJSON("/Home/Refresh", showMovies);
$.ajax({
type: "POST",
contentTyp...
I am using ASP.NET MVC2 and I would like to make up a url based on the current one in the address bar inside a HtmlHelper extension. So far I have this:
url = helper.ViewContext.RequestContext.RouteData.Values
.Aggregate<KeyValuePair<String, Object>>((w, next) => w + next);
But that does not compile. Anyone has a good idea on h...
A followup question to: http://stackoverflow.com/questions/3091705/aggregate-on-dictionary-question.
I used the Aggregate Linq functionality but perhaps there is a better, more clean way, to do it?
Can I get the current route from the HtmlHelper? Or what do you suggest? I want to make a language switcher so as when I am on a page/route...
Please give reference/guidance to make a web application for managing mails(like Microsoft Outlook) in Asp.Net MVC(C#)
We need to implement common functionalities from Microsoft Outlook
sending and receiving email.
Allows user to register mailbox,
change password, and modify user
information.
Allows administrator to create,
delete,...
I'm a desktop app developer, I wanted to study web programming. Is it good to skip ASP.NET and jump into ASP.NET MVC directly? My last experience with web is with PHP, circa 2000
And also, is ASP.NET MVC enterprise-ready(think desktop apps with rich user experience) in terms of components support (be it open-source or commercial ones)...
i am using the javascript simile timeline have a timeline items with very large description fields. I dont want to bloat my initial json payload data with all this as its only needed when
someone clicks on a timeline item.
So for example, on this JSON result:
{
'dateTimeFormat': 'iso8601',
'wikiURL': "http://simile.mit.edu/shelf/"...
I have a multiselect listbox and before submitting the form i want to check whether user select any option or not through jquery
...
Hello Community,
i use asp.net mvc 2 and i have a problem with the DropDownListFor helper.
My ViewModel contains a SelectList with all required Values und 1 SelectedValue.
When i use the DropDownListFor helper in my View the SelectedValue is not selected!
Then i select a other Value and submit the form, on the next rendering in the Post...