Hi,
I’m currently evaluating your Cloud product for my use case and have a question wrt validations.
I’m trying to update a cell with validation. I’m able to get the validation, so it’s there, but I’m able to put any value into the cell.
For my test case, only the value ‘Yes’ or ‘No’ should be valid, but I’m able to put any value in cell A1.
How do I trigger the validation and get feedback whether the value in the cell passes the validation?
Here’s the response -
{
"Cell": {
"Name": "A1",
"Row": 0,
"Column": 0,
"Value": "foo",
"Type": "IsString",
"Formula": null,
"IsFormula": false,
"IsMerged": false,
"IsArrayHeader": false,
"IsInArray": false,
"IsErrorValue": false,
"IsInTable": false,
"IsStyleSet": true,
"HtmlString": "<Font Style=\"FONT-FAMILY: Arial;FONT-SIZE: 10pt;COLOR: #000000;\">foo</Font>",
"Style": {
"link": {
"Href": "/style",
"Rel": "self",
"Title": null,
"Type": null
}
},
"Worksheet": null,
"link": {
"Href": "http://api.aspose.cloud/v1.1/cells/aspose-validation.xlsx/worksheets/Sheet1/cells/A1",
"Rel": "self",
"Title": null,
"Type": null
}
},
"Code": 200,
"Status": "OK"
}
Here’s the validation -
{
"Validation": {
"AlertStyle": "Stop",
"AreaList": [
{
"EndColumn": 0,
"EndRow": 0,
"StartColumn": 0,
"StartRow": 0
}
],
"ErrorMessage": null,
"ErrorTitle": null,
"Formula1": "=Sheet1!$A$3:$A$4",
"Formula2": null,
"IgnoreBlank": true,
"InCellDropDown": true,
"InputMessage": "Click and enter a value from range Sheet1!A3:A4",
"InputTitle": null,
"Operator": "Between",
"ShowError": true,
"ShowInput": true,
"Type": "List",
"Value1": "System.Object[]",
"Value2": null,
"link": {
"Href": "http://api.aspose.cloud/v1.1/cells/aspose-validation.xlsx/worksheets/Sheet1/Validations/0",
"Rel": "self",
"Title": null,
"Type": null
}
},
"Code": 200,
"Status": "OK"
}
Here’s the corresponding spreadsheet -