var
Chart = Matrix.getObject(
'Chart'
);
var
WORKBOOK = {
"FontName"
:
"맑은 고딕"
,
"FontSize"
: 11
,
"WorkSheets"
: [
{
"Name"
:
"Sheet1"
,
"DisplayGridlines"
:
"false"
,
"Controls"
: []
,
"Ranges"
: [
{
"Range"
:
"A1"
,
"ColSpan"
: colspan,
"Value"
: LANGUAGE_EXPORT_REPORT_TITLE +
" "
+Matrix.GetReportInfo().NAME}
,{
"Range"
:
"A2"
,
"ColSpan"
: colspan,
"Value"
: LANGUAGE_EXPORT_USER_NAME +
" "
+Matrix.GetUserInfo().UserName}
,{
"Range"
:
"A3"
,
"ColSpan"
: colspan,
"Value"
: LANGUAGE_EXPORT_CREATE_DATE +
" "
+ nowText}
,{
"Range"
:
"A4"
,
"ColSpan"
: colspan,
"Value"
: LANGUAGE_EXPORT_FILTER_TITLE}
]
}
]
};
WORKBOOK.WorkSheets[0].Controls.push({
"Name"
: Chart.Name,
"Range"
:
"A1:H10"
,
"ImageExport"
:
true
});
Matrix.ExportMXServiceCall(WORKBOOK,
null
,
function
(e) {
if
(e.Success ==
false
){
alert(
"export fail"
+ e.Message);
return
;
}
var
ds = e.DataSet;
var
row = ds.GetTable(0).GetRow(0);
var
folderName = row.GetValue(
"FolderName"
);
var
fileName = row.GetValue(
"FileName"
);
Matrix.DownloadFile(folderName +
"/"
, fileName
, Matrix.GetReportInfo().NAME +
".xlsx"
,
true
,
null
);
}, 2);