I have few questions based on following scenario:
I have a LoginController with following methods:
public ActionResult Login()
{
return View();
}
[HttpPost]
public ActionResult Login(UserObject user)
{
Calling Besiness Service to Validate User againts DB (Using Repository)...
if (success)
{
return RedirectT...
Possible Duplicate:
Asp.net MVC page is giving Mime type warnings for image files
I am working in my ASP.NET MVC app within VS 2010 and so I use the development server for this purpose.
When I enable resource traking on Chrome Developer tool I am seeing a plethora of warnings regarding the images of my app. The warning says:
...
How can I use Html.RadioButtonFor to create radio button which when clicked runs code on the server and controls visibility of certain text box. earlier I used to create <asp:control with autopostback="true" Thanks
...
Hi Guys.
I have a problem. I am developing Asp.Net MVC2 Application with VS2008 very well, but now I want to use the amazing DataAnnotion Validation shipping with Microsoft.MVC.DataAnnotation.dll. I cant find the dll so I found them on the project Site @ http://aspnet.codeplex.com/releases/view/24471#DownloadId=61772
I cant compile th...
Hello Friends, I am getting this Error..
Here is my Web Config file looks like..
<?xml version="1.0" encoding="utf-8"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=152368
-->
<configuration>
<configSections>
<!--<section name="spark" type="Spark...
Background
I have a payment page where the user can select from a list of existing payment methods, or specify a new one. The dropdown presents options such as:
Visa - ******1234 (Saved)
Mastercard - ******9876 (Saved)
[New Credit Card ...]
[New Electronic Check ...]
Using jQuery, I toggle hidden DIVs that contain either an informa...
Hi,
I have a menu which is created from the database.
When the users navigate through pages the current page is highlighted with the css class.
Menu is rendered with the Html.RenderAction("Menu","Home");
Because of being datadriven menu i use the new ChildActionCache attribute which is in the ASP.NET MVC 2 Futures project to cache t...
I have the following 2 classes:
public class SomeClass
{
public int SomeClassID { get; set; }
...
}
public class AnotherClass
{
public int AnotherClassID { get; set; }
public int AnotherClassText { get; set; }
}
I have a ViewModel that contains the following:
public class MyViewModel
{
public SomeClass { get; set; }
publ...
I'm writing an ASP.NET MVC Html Helper which basically takes 2 HTML Helpers that return IHtmlStrings and combines them together and also returns them as an IHtmlString like so:
//this doesn't work
public static IHtmlString CompositeHelper(this HtmlHelper helper, string data)
{
//GetOutput returns an IHtmlString
var output1 = new...
I implemented Facebook-Connect successfully and Im able to retrieve User-Information using the Facebook Toolkit. But I cant sucessfully logout.
When I press the facebook-Logout button (which automatically appears when Im logged in, because im using the autologoutlink-property)
<fb:login-button autologoutlink="true"></fb:login-button>
...
I have a viewmodel that partially looks like this...
[Required]
public int Year { get; set; }
[Required]
[Range(1, 5000000)]
public int ModelID { get; set; }
[Required]
public int ZipCode{ get; set;}
I want to add a custom validator attribute that checks a database to make sure...
Im trying to us a controller in MVC2 to upload a file but i get an object reference not set to an instance of an object error
[HttpPost]
public ActionResult AddPhoto(int id, FormCollection formValues, HttpPostedFile image, AlbumPhotos photo )
{
AlbumPhoto photos = new AlbumPhoto();
UserPhotoAlbum ...
I have a web-forms aspx page (reportviewer) inside a mvc application and I need to create a link to it (ActionLink asks for controller,action pair) and send to it a string and an int,
anybody knows how ?
...
Does any one have any idea about multiproject area support in asp.net mvc 3? As it was degraded to future status in mvc 2. If it is still not included then should we look forward for ASP.Net MVC Portable Areas via MvcContrib. Can you share your expreriences?
What are the recommended way for managing a large application? I read about MEF...
How can you create a route that accept an undefined number of strings?
The folder browser should be able to browse the specified folder and all the sub folders. Using JQuery to get the folders back from the server. The problem is how to build the JQuery?
$.ajax({
type: "POST",
url: "http://localhost:30218/Data/Fol...
I'm quite new to asp.net mvc, and right know I'm trying to find out
a good practise to do input validation.
In the project we're going to use entity framework, where you can add
data annotations to properties in the following way:
[Required(ErrorMessage = "Please enter a product name")]
[Column]
public string Name { get; set; }
This...
We have a project in ASP.net MVC2 were we have our own ViewEngine that overrides were views locations are. Problem is that Resharper 5.1 is not picking up this, of course. Is there anyone who knows of a way to extend R# to pick this up?
I don't want to disable R# to not try to resolve view globally or local with the R# comment. I want ...
How can I integrating an outlook calendar in my web application for managing employees so that I can assign tasks to only those employees not on leave?
...
Can someone also give an example of their use. Perhaps a link explaining them in greater detail? I understand it's for creating your own context objects and for unit testing, but would like more info on their uses. Thanks.
...
hi
I am using MVC 2.0 web application where there few buttons whose onclick i call a action method, but when i press search button for the first time , the action method is called but after that if i try to click the search button the action method is not getting called.
Also let me tell you that i am using the JQ Grid to display the d...