We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

ImportDataTable not available for XAMARIN android

Thread ID:





127599 Nov 27,2016 12:30 PM UTC Nov 28,2016 12:50 PM UTC Xamarin.Forms 1
Tags: XlsIO
Asked On November 27, 2016 12:30 PM UTC

Iam new to xamarin.I have created a Xamarin android project and added Syncfusion package using nuget. 
I have tried to implement the below code but Iam getting an error stating ImportDataTable is not available
ExcelEngine excelEngine = new ExcelEngine();

IApplication application = excelEngine.Excel;

application.DefaultVersion = ExcelVersion.Excel2013;

IWorkbook workbook = application.Workbooks.Create(1);

IWorksheet worksheet = workbook.Worksheets[0];

DataTable table = SampleDataTable();

//Import DataTable to the worksheet.

worksheet.ImportDataTable(table, true, 1, 1);



On further examination I see that only ImportData function is implemented and functions to implement imports of data table and lists are not implemented. I have added references to Syncfusion.XlsIO.Portable and Syncfusion.Compression.Portable. Is this because of any old version of Sync fusion libraries that Iam using. If so , how to download the latest one. (I can see from "Manage nuget package" space that Iam using the latest version of XLSIO.)

Abirami Varadharajan [Syncfusion]
Replied On November 28, 2016 12:50 PM UTC

Hi Divya, 
Thank you for contacting Syncfusion support. 
XlsIO provides portable class library for Xamarin platform. As the data table is not supported in portable platform, so XlsIO doesn’t support import data table into worksheet. However, you can convert the data table into an enumerable object and then import that object into worksheet using Worksheet.ImportData() method.  
To know more about import data into worksheet, kindly refer the following UG documentation link for your reference.

UG documentation link: https://help.syncfusion.com/file-formats/xlsio/working-with-data#import-data-from-business-objects
Please let us know if you have any concern. 


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon