Has anyone had any luck in using the ExportToFile function? I'm trying to setup a scheduled export of form data but with the code below all I get is an excel file that has the correct headers but no datarows, any thoughts?
var excelProvider = Umbraco.Forms.Core.Providers.ExportTypeProviderCollection.Instance.GetProviderInstance(Guid.Parse(Umbraco.Forms.Core.Constants.ExportTypes.Excel));
var formFilter = new RecordExportFilter
{
StartDate = DateTime.Today.AddDays(-14),
EndDate = DateTime.Today,
Form = GuidHelper.GetGuid("ffda27cf-0337-436f-a7de-3f57196531bb"),
};
var formLocation = HostingEnvironment.MapPath("~/App_Data/NewsletterExport.xlsx");
excelProvider.ExportToFile(formFilter, formLocation);
I am having a similar issue. It exports an empty file with headers in a submissions worksheet. Have tried changing filter settings to no avail. Any updates please
ExportToFile function
Has anyone had any luck in using the ExportToFile function? I'm trying to setup a scheduled export of form data but with the code below all I get is an excel file that has the correct headers but no datarows, any thoughts?
Nik
I am having a similar issue. It exports an empty file with headers in a submissions worksheet. Have tried changing filter settings to no avail. Any updates please
is working on a reply...