Hello,
const processesList: string[] = ["Process 1","Process 2","Process 3"];
I want to add the word I wrote in the cell to the "list of validation" if it is not in the current list.
SpreadValidation() {
var spreadsheet = kendo.jQuery(this.spreadsheetEl.nativeElement).data("kendoSpreadsheet");
var sheet = spreadsheet.activeSheet();
const processesMerge = '"'+processesList.toString()+'"';
sheet.range("B:AX").validation({
dataType: "list",
showButton: true,
comparerType: "list",
from: processesMerge,
allowNulls: true,
type: "warning"
});
}
change listener code
var spreadsheet = kendo.jQuery(this.spreadsheetEl.nativeElement).data("kendoSpreadsheet");
spreadsheet.bind("changing", this.changeListener);
changeListener(e) {
console.log("The netered value is: "+e.data);
processesList.push(e.data);
var spreadsheet = $("#spreadsheet").data("kendoSpreadsheet");
var sheet = spreadsheet.activeSheet();
const progressMerge = '"'+processesList.toString()+'"';
sheet.range("B:AX").validation({
dataType: "list",
showButton: true,
comparerType: "list",
from: progressMerge,
allowNulls: true,
type: "warning"
});
}
I can capture the data I entered in the cell, but I could not add this word to the current validation list. how can I do it ?
My goal is that if the added word is not in the validation list, it will be added, and if there is, it will not repeat the data. in this way, it is always to increase the list and to be able to make a selection from the existing ones.
like this, it just adds the cell I changed to the validation. I want this list to change in all validations between B:AX
Can I access the spreadsheet from e?