Questions tagged [remote-validation]

Remote Validation is the ability to call a custom server-side validation method via the client-side.

159 questions
4
votes
2 answers

Loading indicator for MVC3 unrobustive remote validation

I am doing the MVC3 unrobustive remote validation for checking username availability. It works fine, but it takes quite some time load the validation message! Is there any way to show a spinner/user name available checking message during the…
4
votes
2 answers

Show Custom Message for remote validation success response

I am using remote validation to check the availability of username during registration for my asp.net mvc 3 applicaion (C#). I am using MVC remote Attribute validation as: [Remote("IsUserNameAvailable", "User")] public string UserName { get; set;…
Prasad
  • 56,343
  • 61
  • 142
  • 199
4
votes
3 answers

onClick remote validation for dropdown field

I am using JQuery remote validation on drop-down field to check whether the selected field already exists or not. The overall code is working fine and validates properly. But the issue is remote validation sending an ajax call after onChange event,…
J.K.A.
  • 6,566
  • 23
  • 88
  • 151
4
votes
0 answers

ASP.NET MVC4 - Remote validation on a collection object

I'm at my wit's end trying to figure out a way to make this work. I have an ASP.NET MVC4 View which is strongly typed to a ViewModel which contains a number of collection objects. One of those objects is a list of column headers public…
user2146445
  • 143
  • 6
4
votes
3 answers

Remote validation doesn't pass data to action

I have model: public class MyModel ...fields [Remote(ActionName, ControllerName)] public string SomeNumber { get; set; } ..fields And have a action in ControllerName controller: public JsonResult ActionName(string someNumber) {...} But when…
Roman Bats
  • 1,682
  • 3
  • 26
  • 38
4
votes
2 answers

MVC Remote Validation - Clear or set additional field errors

We have 2 input textfields on the screen whose combination makes up a valid entry. We are doing remote validation on both of them. Our ViewModel: [Remote("IsExampleValid", "Validation", AdditionalFields = "Field2")] public int Field1 { get; set;…
user1167865
  • 115
  • 6
4
votes
3 answers

Parameter Name in Remote Model Validation Action of MVC3

I use Remote validation attribute for SSN property, In view Page I use generic view then the ssn field is like: @Html.EditorFor(model => model.MainModel.SSN) @Html.ValidationMessageFor(model => model.MainModel.SSN) and My Action is: public…
Saeid
  • 12,286
  • 26
  • 98
  • 166
3
votes
3 answers

Remote Validation seems buggy

imagine this situation: SetUp in the default MVC3 project, create a new complex type in the AccountModels.cs public class GlobalAccount { public GlobalAccount() { this.LogOn = new LogOnModel(); this.Register = new…
balexandre
  • 69,002
  • 44
  • 219
  • 321
3
votes
2 answers

Remote Validation for LIST of MODELs

I used the following tutorial: http://msdn.microsoft.com/en-us/library/gg508808%28VS.98%29.aspx And everything seemed fine, but in my case, string Username always comes back null. After tonnes of research, I found everyone discovered BIND Prefixes.…
3
votes
2 answers

jQuery validation group with Remote Validation MVC 3

I want to validate a date of birth with a RemoteValidation/jQuery from 3 selectors. I want to check if a user is 18 or older. But atm i'm having some trouble to group them so they are invalid/valid together and with only one errormessage. Goal: i…
mannge
  • 351
  • 1
  • 5
  • 12
2
votes
0 answers

Client side validation routine that includes Ajax

Is it possible to include Ajax in a client-side validation script (using jQuery unobtrusive validation as the framework) and still have validation behave properly? I have a validation scenario in which the client needs to send some user-entered…
Ann L.
  • 12,802
  • 5
  • 30
  • 60
2
votes
4 answers

MVC3 Remote Validation of a field within a List

For some reason, whenever I try to remotely validate a primitive property inside an array within my model, the value of the property is not passed as a parameter. For example, when my remote validation method (UniqueItemNo) is called, the string…
Steven
  • 47
  • 1
  • 8
2
votes
1 answer

ASP.Net mvc 3.0 remote validation

I have this problem: I am validating a model in which the sum of 2 attributes can`t be greater than 100. For this i am using as follow: In my model these are my attributes: [Remote("ValidatePrevTextWidth", "Validation", AdditionalFields =…
Matias Varini
  • 51
  • 1
  • 4
2
votes
1 answer

ASP.Net MVC3: Remote validation calls not firing

I have a data entry form that has remote validation set up to check for existing values in the database for a certain field. Here's what happens: Go to Create page (data entry form). Enter value X for field. Field loses focus. Remote validation…
Ann L.
  • 12,802
  • 5
  • 30
  • 60
2
votes
3 answers

Asp.net MVC: Additional fields are not binding for Remote validation

I have list of models and want to perform remote validation. Model: [System.Web.Mvc.Remote("Method", "Controller", HttpMethod = "POST", AdditionalFields = "prop2,prop3", ErrorMessage = "Error")] public string prop1 { get; set; } The name…
Jayakrishnan
  • 3,724
  • 2
  • 17
  • 29
1
2
3
10 11