TEXTSPLIT not working

Hi,


I have a simple console application where I want to test how TEXTSPLIT works but it doesn't give me the values of the cells. Can anyone tell me what I'm doing wrong?

Here is the code 


using Syncfusion.XlsIO;



using (ExcelEngine excelEngine = new ExcelEngine())

{

    //Initialize application

    IApplication app = excelEngine.Excel;

    app.EnableIncrementalFormula = true;

    //Set default application version as Xlsx

    app.DefaultVersion = ExcelVersion.Xlsx;


    //Open existing Excel workbook from the specified location

    string inputFileName = @"url";


    Stream fileStream = File.OpenRead(inputFileName);

    IWorkbook workbook = app.Workbooks.Open(fileStream);

    workbook.SetSeparators(';', ',');

    workbook.CalculationOptions.CalculationMode = ExcelCalculationMode.Automatic;


    IWorksheet worksheet = workbook.Worksheets[0];

    worksheet.EnableSheetCalculations();

    worksheet["A1"].Text = "Excel|Test";



    Console.WriteLine(worksheet["A2"].CalculatedValue);

    Console.WriteLine(worksheet["A2"].DisplayText);


    Console.WriteLine(worksheet["A3"].CalculatedValue);

    Console.WriteLine(worksheet["A3"].DisplayText);


    worksheet.DisableSheetCalculations();

}


Result: 


#NAME?

#VALUE!


6 Replies

KM Kurmitha Manickhaperumal Syncfusion Team April 17, 2024 01:05 PM UTC

Hi Jordan,

 

Please refer to the attached sample for how text split works using XlsIO.

 

Regards,
kurmitha M.


Attachment: TextSplit_481b3355.zip


JD Jordan de Vogelaere replied to Kurmitha Manickhaperumal April 17, 2024 01:20 PM UTC

Hi, 


Thanks for your reply. 

What I'm actually trying to achieve is when I added a value in a cell like in cell A1 in the example that cell A2 reacts to this because in cell A2 there is a TEXTSPLIT function. Is this something that is working?


See attached excel. 


Kind regards,

Jordan


Attachment: samp1.xlsx_836f0747.zip


KM Kurmitha Manickhaperumal Syncfusion Team April 18, 2024 02:22 PM UTC

Hi Jordan,

 

Please refer to the modified sample where the Excel file loads with text split occurring in cell A2, and entering a value in cell A1, the cell updates accordingly.

 

Also, XlsIO currently does not have calculate support for TEXTSPLIT formula. We have logged this as a feature "Calculate support for TEXTSPLIT formula in XlsIO " request. We will implement this feature in one of our upcoming releases.

 

You can track the status of the feature through the feedback link.

 

Regards,

Kurmitha M.


Attachment: TextSplit_12f3441b.zip


JD Jordan de Vogelaere replied to Kurmitha Manickhaperumal April 19, 2024 07:58 AM UTC

Hi, 

Thanks for your answer. Where can I find a list of formulas that supports calculation? We actually use the library to calculate values based upon a configured excel file so it's important for us to know which formulas can be used. 


Thanks,


Kind regards,

Jordan



KM Kurmitha Manickhaperumal Syncfusion Team April 23, 2024 03:19 PM UTC

Hi Jordan,

 

Please refer to the attached Excel file for unsupported calculate values in XlsIO. We will document this in near future.

 

Regards,

Kurmitha M.


Attachment: UnsupportedCalculate_3b342d4a.xlsx


JD Jordan de Vogelaere replied to Kurmitha Manickhaperumal September 11, 2024 07:54 AM UTC





Loader.
Up arrow icon