We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Problem with OnCellUpdated event


I am using Aspose in a Web Application.

I want to set some style on a cell on OnCellUpdated event. But I am facing some issues.
The cell on which I make my tests is used in a formula in another cell.
Then when I modify my cell and I try to catch the new value of my cell I get the new value of the result of the formula of the other cell…
Is there a way to catch the cell updating manually by the user ?

I have another question : is there a way to get the value of a cell by row index and column index but of another sheet than the active one ?

You can see my code below :

function OnCellUpdated(cell) {
var gridWeb = document.getElementById(’<%=gridWebCalculationArea.ClientID%>’);

var sheetTabIndex = gridWeb.acttab;
var rowIndex = gridWeb.getCellRow(cell);
var columnIndex = gridWeb.getCellColumn(cell);

alert(columnIndex); //issue here I get 17 which is the index of the formula’s cell instead of 15

var newValue = gridWeb.getCellValue(rowIndex, columnIndex);
alert(newValue); //Then here i logically get the new result of the formula’s cell…

//Here i want to get the value of the cell which have the same row index and column index than the updated cell but in another sheet (hidden one). It doesn’t work.
var processHiddenSheet = document.getElementById(’<%=gridWebCalculationArea.ClientID%>_TAB5’);
var oldValue = processHiddenSheet.getCellValue(rowIndex, columnIndex);

Well I apologize i found the solution to get the manually updated cell in another thread on your forum.
I use the parameter “isOriginal” and it works fine !

So there is just the problem to get a cell value from another sheet.


Well, you may try Aspose.Cells.GridWeb server side API to accomplish your task but I am there is no such API on the client side (in JavaScript) to do it. We will check if we can provide you some workaround or other way if possible or may log a ticket for it (we need to evaluate it first if this is possible/feasible or not).

Currently you may try using the server side APIs provided by Aspose.Cells.GridWeb control:

Sample code:

//Accessing the second worksheet of the Grid
WebWorksheet sheet = GridWeb1.WebWorksheets[1];

//Accessing “B1” cell of the worksheet
WebCell cell = sheet.Cells[“B1”];

//Accessing the string value of “B1” cell
string cellVal = cell.StringValue;

Thank you.


Yes I know that it is possible on server side. I used that before.
But we have some response time issue and that’s why I need to do it on client side to avoid go/back to server (I am using Ajax).
If it is possible to improve the API on client side to provide the possibility to do this in JavaScript it will be great !



Well, as I told you before there is no such API on the client side (in JavaScript) to do it, it might not be feasible enough to do it on the client end. We recommend you to kindly use Server side APIs, if you find any significant performance issue, kindly provide us more details (you may start a new thread if possible) and provide us a sample project, we will evaluate your issue soon.

Thank you.