Free Support Forum - aspose.com

RefferedArea as result of parameter's calculation

Good day.


I have founded a some issue, that blocked my development. I need to check a some parameter of custom function for belonging a referred area. There is example:

public static class ISCELL implements ICustomFunction {

public static Integer CONTEXT_REFERRED_AREAS = 4;

private static ReferredArea getReferredArea(ArrayList contextObjects, int index) {
ReferredAreaCollection areas = (ReferredAreaCollection) contextObjects.get(CONTEXT_REFERRED_AREAS);
return areas == null || areas.getCount() <= index ? null : areas.get(index);
}

protected static boolean isCellRef(ArrayList contextObjects, int index) {
return getReferredArea(contextObjects, index) != null;
}


@Override
public Object calculateCustomFunction(String s, ArrayList paramValues, ArrayList contextObjects) {
if (“ISCELL”.equals(s)) {

return isCellRef(contextObjects, 0) ? 1 : 0;

}

return null;
}
}

@Test
public void formulaTest() {

try {

Workbook wb = new Workbook(“D://test.xls”);
Worksheet sheet = wb.getWorksheets().get(0);

wb.calculateFormula(true, new ISCELL());

assertEquals(1, (int)sheet.getCells().get(“B3”).getValue());


} catch (Exception e) {
e.printStackTrace();
assertNull(e);
}

}

May be i have selected wrong way for checking a referred area.
Hi,

Thanks for sharing some details and the sample code.

Well, currently Aspose.Cells fetches and transfers parameters for cell values in calculating custom functions. We think you need to get a reference for the cells instead of values. We need to evaluate your requirements in details and we will get back to you soon.

Thank you.

Hi Amjad Sahi.


Thanks for quick reply. But i want to correct issue - you have already transer an refferedAreas array in contextObjects. Now you just needed to add in this array result of calculation a function parameter, that represents as formula with refferedArea as result.

I think, it should be not complex.

Best regards.

Hi,


I have logged a ticket with an id “CELLSJAVA-40734” for your issue/requirements. We need to evaluate your issue first and if we can figure it out. We will look into it soon.

Once we have any update on it, we will let you know here.

Thank you.

Hi Amjad Sahi. Can you please refresh information about this feature? It is very important feature for us.

Hi Nikolaj,

I am afraid, the ticket logged earlier as CELLSJAVA-40734, is currently pending for analysis, and is in the queue with other tasks. We can not share estimated release schedule unless we have properly analyzed the request on our end. Please spare us little more time for feature analysis. Once we have any updates, we will post here for your kind reference.

Hi,


We have evaluated your issue in details. Well, We cannot support it now as we have some other important tasks to be implemented. Currently, we only can return a RefferedArea object when the formula is such as, "=ISCELL(A1)". We are planning to rebuild our formula calculation engine to fix this issue.

We hope we can implement this enhancement in Q2 2014.

Thank you.

Hello.


What about this issue? Can you please provide some preliminary timeframe?

Best regards. Alexey

Hi Alexey,


As I shared above ( in my previous reply), the initial eta is Q2 2014 (i.e., before the end of June 2014). Hopefully, we will accomplish it in due date/time. If there is some change in the schedule, we will share it here.

Thank you.

Hello. How r u? There is some changes relative this task?

Hi Alexey,

Thanks for using Aspose.Cells.

We are afraid, there is no update for you regarding this issue at this moment. However, we have logged your comment in our database and requested the development team to provide some update. Once, there is some news for you, we will let you know asap.

Hi,

Thanks for using Aspose.Cells.

We are sorry to tell the you that we cannot support it in time. The refactor
of the formula calculation engine is more complicated than we had planned and
also there are some other important tasks blocked the refactor process. We will
try to finish this task in Q3.

Hi,
Do you have any good news about this issue?

Hi,

I have checked the status of the issue "CELLSJAVA-40734" into our database, it is in progress and not resolved yet.

Once we have any update on it, we will be more than happy to share it here.

Thank you.

Hi,


Do you have updates about the issue ?
Hi,

Thanks for your posting and using Aspose.Cells.

Currently we have finished the main development of the new formula calculation engine and are in the process of testing it thoroughly. We are afraid we need at least one more month to finish the test and give a stable release for it.
Hi. When we could be expected this feature for us?

Best regards. Alexey

Hi Alexey,

Thanks for your posting and using Aspose.Cells.

We are afraid, there is no update for you at this moment. However, we have logged your comment in our database against this issue and requested the development team to provide some update. Once, there is some news for you, we will let you know asap.

Hi,


It is to inform you that we have fixed your issue logged earlier as “CELLSJAVA-40734”. Hopefully we could provide you the fix in the next few days after performing QA and incorporating other enhancements and fixes.

Keep in touch.

Thank you.

Hi,

Thanks for using Aspose.Cells.

We have fixed this issue.

Please download and try the latest fix: Aspose.Cells
for Java v8.4.2.5
and let us know your feedback.