We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

how to perform validation for dropdown in gridview

Thread ID:

Created:

Updated:

Platform:

Replies:

120503 Sep 22,2015 01:03 AM Sep 23,2015 07:27 AM JavaScript 1
loading
Tags: ejGrid
Bharat Buddhadev
Asked On September 22, 2015 01:03 AM

e-columns="columns"
class="gridStyle"
e-allowresizing="true"
e-allowkeyboardnavigation="true"
e-allowscrolling="true"
e-allowsorting="true"
e-minwidth="550"
e-isresponsive="true"
e-scrollsettings-height="320"
>
var dropList = [
{ empid: "SelectedRowIndex", text: "SelectedRowIndex" }, { empid: "ViewRecord", text: "ViewRecord" }
];
var data = [
{ OrderID: 10248, EmployeeID: 1 },
{ OrderID: 10249, EmployeeID: 2 },
{ OrderID: 10250, EmployeeID: 3 },
{ OrderID: 10251, EmployeeID: 4 },
{ OrderID: 10252, EmployeeID: 5 }
];
$scope.setTargetList = function (targetList) {
$scope.data = data;
$scope.list = dropList
}
If we generate column in this way into grid than how to perform validation with column using jquery add method
for dropdown
2) if I will include extra textbox and in this way how to perform validation for that extra textbox.

Ragavee U S [Syncfusion]
Replied On September 23, 2015 07:27 AM

Hi Bharat,

We are quite unclear on your query to perform validation with dropdown column.

As of now, we have created a sample with validation: {required: true} to the dropdown column, which can be downloaded from the following location.

Sample Link: http://jsplayground.syncfusion.com/lye0q1x3

In the above sample, we have bound dropDown dataSource with one blank value. On selecting the blank value on editing and saving, the validation message is popped.

Query: if I will include extra textbox and in this way how to perform validation for that extra textbox.

By above query, do you mean to set validation for other columns upon adding/editing. We can set the jquery validation for the columns using the validation property under the ejGrid columns api. If your query differs from our understanding,

Please share the below details
1.       jquery validation rule that you are expecting to apply to the dropdown column
2.       Are you expecting to set validation to the dropdown column based on another column value
3.       Explain what you actually meant by “if I will include extra textbox and in this way how to perform validation for that extra textbox.
4.       Share more and clear details on your requirement.

Regards,
Ragavee U S

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;