Tag Archives: excel

Unable to export data to excel sheet using tabulator plugin

Questions: I am using Tabulator Plugin to load my data into my html. For that I am using this code in my javascript: var j = $( “#example-table” ).hasClass( “tabulator” ) console.log(res[“data”]); if (j) { $(“#example-table”).tabulator(“destroy”); } $(“#example-table”).tabulator({ layout:”fitColumns”}); //set new columns $(“#example-table”).tabulator(“setColumns”, res[“column”]); //set new data $(“#example-table”).tabulator(“setData”, res[“data”]); $(“#download-xlsx”).click(function(){ $(“#example-table”).tabulator(“download”, “xlsx”, “data.xlsx”); }); $(“#download-csv”).click(function(){… Read More »

Loading DataTable from Excel: Unable to cast object of type 'System.DateTime' to type 'System.String'

Questions: I am trying to create a Datatable reading an excel file, which has a DateTime Column,rest all other columns are string. When trying to convert the DateTime column to Datetime Datatype ,I get an exception “Unable to cast object of type ‘System.DateTime’ to type ‘System.String’.” Could someone please guide me how do I resolve… Read More »

Dates being flipped through inter op excel

Questions: I am having a strange issue with dates in excel at present some dates when exported from my grid while displaying file are swapping the month and days however I used the number format to account for this but still some items seems to have an issue. private static void ExportToExcel(List<ListViewItem> items, ListView listView)… Read More »

C# write objectlist to excel with Epplus

Questions: I want to create an excel file from an objectList. The objectList has a List<int> as well and when i want to write the objectlist to excel it only takes the first item(position 0) from the List<int> in the objectlist and not the entire list. this is the object (with the public class FileChangeset… Read More »

How to write an Excel file in ASP.NET?

Questions: I just want to write a Excel file in ASP.NET via Microsoft.Office.Interop.Excel.dll. When I run my code in Visual Studio, it works great, but when I publish it to IIS, I get this error and it does not create my Excel file: Microsoft Excel cannot open or save any more documents because there is… Read More »

C# export mysql database to excel file

Questions: Hi i created a pos software but i needed a function to export data to excel so i created a class to export and i get and error when i try to export the file so here is some of my code that i worked on. public void PrefrlivoExcel() { MySqlConnection connection = Connection.prevzemiKonekcija();… Read More »