Need Info on Aspose.Cells method cell.setValue(String-boolean)

Hi,

I'm upgrading the Aspose.Cells for Java version that we have to the latest that our license allows (v7.0.1). I've been using the Migration document you have provided on the site (thanks its a great help). I've come across this function which apparently has been deprecated, but there's no info on it:

cell.setValue (java.lang.String, Boolean)

I'm upgrading code that I did not initially write so I'm not sure of the logic used in Aspose.Cells for the boolean and I can't find an old API that would tell me.

Your feedback on this would be great.

The old version I'm upgrading from is v2.4.1.0

Regards

Denise

Hi Denise,

Thanks for your posting and using Aspose.Cells.

FYI:

void setValue(java.lang.String stringValue, boolean isConverted)
Sets a string value into the cell and converts the value to other data type if appropriate.

For example, the following string will be converted to date type

cell.setValue(“20-jul-2015”, true);

and following string will be converted to number

cell.setValue(“2015”, true);

and following string will remain string

cell.setValue(“jul”, true);

You should now use

void putValue(java.lang.String stringValue, boolean isConverted)
Puts a string value into the cell and converts the value to other data type if appropriate.

i.e

cell.putValue(“20-jul-2015”, true);

Thanks so much Shakeel.

Regards

Densie

Hi,


Good to know that your issue is sorted out now. Feel free to write back if you have further queries or comments, we will be happy to assist you soon.

Thank you.