SmartClient Version: v11.0p_2016-04-22/EVAL Development Only (expires 2016.06.21_11.05.07) Licensed to: Isomorphic Software (#ISC_EVAL_NIGHTLY)
Chrome on OSX
Hello, please modify the #FSexport sample like this:
then, if you export in xls format, you'll see 'true' and 'false' for the member_g8 field.
Is it possible to display 'yes' and 'no', like when you don't have valueIcons for the field?
Chrome on OSX
Hello, please modify the #FSexport sample like this:
Code:
isc.ListGrid.create({
ID: "countryList",
width:500, height:250, top:70, alternateRecordStyles:true,
dataSource: worldDSExport,
autoFetchData: true,
fields:[
{name:"countryName", title:"Country"},
{name:"capital", title:"Capital"},
{name:"continent", title:"Continent"},
{name:"independence", title:"Nationhood", width:100},
{name:"member_g8", title:"member_g8", valueMap:{true:"yes", false:"no"}, type:"text",
imageURLPrefix: "flags/16/", imageURLSuffix: ".png",
showValueIconOnly: false, valueIcons: {true: "IT", false: "US"}
}
],
showFilterEditor: true
});
isc.DynamicForm.create({
ID: "exportForm",
width:300,
fields: [
{ name: "exportType", title: "Export Type", type:"select", width:"*",
defaultToFirstOption: true,
valueMap: {
"csv" : "CSV" ,
"xml" : "XML",
"json" : "JSON",
"xls" : "XLS (Excel97)",
"ooxml" : "OOXML (Excel2007)"
}
},
{ name: "showInWindow", title: "Show in Window", type: "boolean", align:"left" }
]
});
isc.Button.create({
ID: "exportButton",
title: "Export",
left: 320,
click: function () {
var exportAs = exportForm.getField("exportType").getValue();
var showInWindow = exportForm.getField("showInWindow").getValue();
if (exportAs == "json") {
// JSON exports are server-side only, so use the OperationBinding on the DataSource
countryList.exportData({ operationId: "customJSONExport",
exportDisplay: showInWindow ? "window" : "download"});
} else {
// exportAs is not JSON, so we can set that with requestProperties
countryList.exportClientData({ exportAs: exportAs,
exportDisplay: showInWindow ? "window" : "download"
});
}
}
});
Is it possible to display 'yes' and 'no', like when you don't have valueIcons for the field?
Comment