Exporting Data to Excel

i use the below link example to exportToExcel
docs.dhtmlx.com/scheduler/excel.html

if i use this function scheduler.exportToExcel(), it download only empty excel sheet with startDate, endDate and text column.

and also i try the same function with optional properties(like below), but it only showing new tab, not downloading anything.

scheduler.exportToExcel({
{ name:“My document”, columns:[
{ id:“text”, header:“Title”, width:150 },
{ id:“start_date”, header:“Start date”, width:250 }
]}
});

Can Anyone Please tell me how to do ExportToExcel…

its very Important for client? I am waiting for reply…

Please,.

Use full file name, like name:“MyDocument.xlsx”

docs.dhtmlx.com/scheduler/snippet/9a5a0334

Thanks For Your reply.
but still i didnt get it… it downloading empty excel sheet with headers…

my coding:

scheduler.init(“scheduler_here”, “”, “month”);
scheduler.load(‘EmpSchedular_LoadData.ashx’);

    function expsch() {
        scheduler.exportToExcel({
            name: "MyDocuments.xlsx",
            columns: [{ id: "text", header: "Project Code" },
                        { id: "start_date", header: "Start date" },
                        { id: "end_date", header: "End date" }                        
                    ]
        });
    }

    <input type='button' value='export' onclick='expsch()'>

Server Side (EmpSchedular_LoadData.ashx) :
dhtmlxSchedulerConnector connector = new dhtmlxSchedulerConnector(
“Select Tbl_ProjectCode_Master.PcId …”
, “Resource_id” // Primary key
, dhtmlxDatabaseAdapterType.SqlServer2005
, ConfigurationManager.ConnectionStrings[“ResourceConn”].ConnectionString
, “Resource_start_date as start_date”
, “Resource_end_date”
, “ProjectCode as text, CompName, NatureName, MonthYear, Comp_AreaName, UnitName, Resource_name”
);

The export code is valid ( docs.dhtmlx.com/scheduler/snippet/461de05c )

Problem can be caused by invalid data feed. Do you see correct events in scheduler before export ?
Can you share the sample of dhtmlxSchedulerConnector output ?

events are binding to calendar correctly.
what u mean by, sample of dhtmlxSchedulerConnector output ?


raw xml data generated by connector, it is not actual anymore as, according to the above screen, data was loaded correctly.

then why its not coming?

what i have to do now?
please…

Not sure, the similar sample ( exactly the same client side code ) works for me.
If issue still occurs - please provide a demo link or a full sample which can be opened locally.

Finally find it out the Problem…

if i use the below link. My Export to Excel will download the blank Excel sheet.

After i remove the link, it will downloaded the excel sheet with task correctly.

can anyone knows this reason.?

You are right.

There was a problem with recurring events.
In recurring mode scheduler can’t export ALL events, as recurring events can be created without end date, which will result in infinite list of events. So you need to use the start and end dates

http://docs.dhtmlx.com/scheduler/snippet/8f1e20f8

scheduler.exportToExcel({ start:new Date(2009,0,1), end: new Date(2011, 0, 1) });

Be sure to clear cache as api.js was updated as well.