Child pages
  • excelxport

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3
{div:style=}
Wiki Markup
Div
styledisplay:none

DO

NOT

EDIT

THE

CONTENT

OF

THIS

PAGE

DIRECTLY

(EXCEPT

INSIDE

THE

DIV

BELOW

WITH

ID=DESCRIPTION),

UNLESS

YOU

KNOW

WHAT

YOU'RE

DOING.


THE

STRUCTURE

OF

THE

CONTENT

IS

VITAL

IN

BEING

ABLE

TO

AUTO

UPDATE

THE

CONTENT

THROUGH

THE

DOC

GENERATOR.\\ \\ Enter additional information related to this 'class' inside the \{div} macro with 'id=description'{div} {div:id=description}This plugin allows the enabling/disabling of the Smart Client menuitems that expose the generic Excel import/export logic{div}\\ {table:id=|class=servoy sSummary}{colgroup}{column:width=80px|padding=0px}{column}{column}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=2}Property Summary{th}{tr}{tbody}{tr}{td}[Boolean]{td}{td}[#exportEnabled] Enable the export feature of this plugin.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#importEnabled] Enable the import feature of this plugin.{td}{tr}{tbody}{table}\\ {table:id=|class=servoy sSummary}{colgroup}{column:width=80px|padding=0px}{column}{column}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=2}Method Summary{th}{tr}{tbody}{tr}{td}byte[]{td}{td}[#excelExport]\(foundSet, dataProviderIds) Export to Excel data{td}{tr}{tbody}{tbody}{tr}{td}byte[]{td}{td}[#excelExport]\(foundSet, dataProviderIds, templateXLS) Export to Excel data{td}{tr}{tbody}{tbody}{tr}{td}byte[]{td}{td}[#excelExport]\(foundSet, dataProviderIds, templateXLS, sheetName) Export to Excel data{td}{tr}{tbody}{tbody}{tr}{td}byte[]{td}{td}[#excelExport]\(foundSet, dataProviderIds, templateXLS, sheetName, startRow) Export to Excel data{td}{tr}{tbody}{tbody}{tr}{td}byte[]{td}{td}[#excelExport]\(foundSet, dataProviderIds, templateXLS, sheetName, startRow, startColumn) Export to Excel data{td}{tr}{tbody}{table}\\ {table:id=property|class=servoy sDetail}{colgroup}{column:width=100%|padding=0px}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=1}Property Details{th}{tr}{tbody:id=exportEnabled}{tr:id=name}{td}h6.exportEnabled{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}

GENERATOR.

Div
iddescription
This plugin allows the enabling/disabling of the Smart Client menuitems that expose the generic Excel import/export logic



HTML Table
id
classservoy sSummary
Colgroup Tag
Col
width80px
Col
Table Head (thead)
Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Property Summary
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
exportEnabled
Enable the export feature of this plugin.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
importEnabled
Enable the import feature of this plugin.



HTML Table
id
classservoy sSummary
Colgroup Tag
Col
width80px
Col
Table Head (thead)
Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Method Summary
Table Row (tr)
Table Cell (td)
byte[]
Table Cell (td)
excelExport(foundSet, dataProviderIds)
Export to Excel data
Table Row (tr)
Table Cell (td)
byte[]
Table Cell (td)
excelExport(foundSet, dataProviderIds, templateXLS)
Export to Excel data
Table Row (tr)
Table Cell (td)
byte[]
Table Cell (td)
excelExport(foundSet, dataProviderIds, templateXLS, sheetName)
Export to Excel data
Table Row (tr)
Table Cell (td)
byte[]
Table Cell (td)
excelExport(foundSet, dataProviderIds, templateXLS, sheetName, startRow)
Export to Excel data
Table Row (tr)
Table Cell (td)
byte[]
Table Cell (td)
excelExport(foundSet, dataProviderIds, templateXLS, sheetName, startRow, startColumn)
Export to Excel data



HTML Table
idproperty
classservoy sDetail
Colgroup Tag
Col
colspan2
width100%
Col
Table Head (thead)
Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Property Details
Table Body (tbody)
idexportEnabled
Table Row (tr)
idname
Table Cell (td)

exportEnabled

Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Enable the export feature of this plugin.
Table Row (tr)
idret
Table Cell (td)

Returns

Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)

Sample

Div
classsIndent
Code Block
languagejavascript
plugins.excelxport.exportEnabled = true;
var isEnabled = plugins.excelxport.exportEnabled;
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=importEnabled}{tr:id=name}{td}h6.importEnabled{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)
 
Table Body (tbody)
idimportEnabled
Table Row (tr)
idname
Table Cell (td)

importEnabled

Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Enable the import feature of this plugin.
Table Row (tr)
idret
Table Cell (td)

Returns

Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)

Sample

Div
classsIndent
Code Block
languagejavascript
plugins.excelxport.importEnabled = true;
var isEnabled = plugins.excelxport.importEnabled;
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{table}\\ {table:id=function|class=servoy sDetail}{colgroup}{column:width=100%|padding=0px}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=1}Method Details{th}{tr}{tbody:id=excelExport-JSFoundSet_StringArray}{tr:id=name}{td}h6.excelExport{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}byte[]{span}{span:style=font-weight: bold;}excelExport{span}{span}\(foundSet, dataProviderIds){span}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[JSFoundSet]} foundSet -- the foundset on which to export \{[String]\[]} dataProviderIds -- the ids of the dataproviders {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}byte[]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)
 



HTML Table
idfunction
classservoy sDetail
Colgroup Tag
Col
colspan2
width100%
Col
Table Head (thead)
Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Method Details
Table Body (tbody)
idexcelExport-JSFoundSet_StringArray
Table Row (tr)
idname
Table Cell (td)

excelExport

Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
byte[]
Span
stylefont-weight: bold;
excelExport
Span
(foundSet, dataProviderIds)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Export to Excel data
Table Row (tr)
idprs
Table Cell (td)

Parameters

Div
classsIndent
{JSFoundSet} foundSet - the foundset on which to export
{String[]} dataProviderIds - the ids of the dataproviders
Table Row (tr)
idret
Table Cell (td)

Returns

Div
classsIndent
byte[]
Table Row (tr)
idsam
Table Cell (td)

Sample

Div
classsIndent
Code Block
languagejavascript
//export in new byte array
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name']);
//export by adding to templateXLS in default (new) 'Servoy Data' worksheet
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS);
//export by adding to templateXLS, in 'mySheet' worksheet, starting at default(1/1) row/column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet');
//export by adding to templateXLS, in 'mySheet' worksheet, starting at 3rd row and 5th column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet',3,5);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)
 
Table Body (tbody)
idexcelExport-JSFoundSet_StringArray_byteArray
}{
Table Row (tr)
:
id
=
name
}{td}h6.excelExport{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)

excelExport

Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}
byte[]
{span}{span:style=
Span
stylefont-weight:
bold;
}
excelExport
{span}{span}\
Span
(foundSet,
dataProviderIds,
templateXLS)
{span}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[JSFoundSet]} foundSet -- the foundset on which to export \{[String]\[]} dataProviderIds -- the ids of the dataproviders \
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Export to Excel data
Table Row (tr)
idprs
Table Cell (td)

Parameters

Div
classsIndent
{JSFoundSet} foundSet - the foundset on which to export
{String[]} dataProviderIds - the ids of the dataproviders
{byte[]}
templateXLS
-
-
the
xls
template
to
export
in {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}byte[]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
in
Table Row (tr)
idret
Table Cell (td)

Returns

Div
classsIndent
byte[]
Table Row (tr)
idsam
Table Cell (td)

Sample

Div
classsIndent
Code Block
languagejavascript
//export in new byte array
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name']);
//export by adding to templateXLS in default (new) 'Servoy Data' worksheet
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS);
//export by adding to templateXLS, in 'mySheet' worksheet, starting at default(1/1) row/column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet');
//export by adding to templateXLS, in 'mySheet' worksheet, starting at 3rd row and 5th column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet',3,5);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)
 
Table Body (tbody)
idexcelExport-JSFoundSet_StringArray_byteArray_String
}{
Table Row (tr)
:
id
=name}{td}h6.excelExport{td}{tr}{tr:id=sig}{td}{span:style=
name
Table Cell (td)

excelExport

Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}
byte[]
{span}{span:style=
Span
stylefont-weight:
bold;
}
excelExport
{span}{span}\
Span
(foundSet,
dataProviderIds,
templateXLS,
sheetName)
{span}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[JSFoundSet]} foundSet -- the foundset on which to export \{[String]\[]} dataProviderIds -- the ids of the dataproviders \
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Export to Excel data
Table Row (tr)
idprs
Table Cell (td)

Parameters

Div
classsIndent
{JSFoundSet} foundSet - the foundset on which to export
{String[]} dataProviderIds - the ids of the dataproviders
{byte[]}
templateXLS
-
-
the
xls
template
to
export
in
\

{
[
String
]
}
sheetName
-
-
the
name
of
the
worksheet {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}byte[]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
worksheet
Table Row (tr)
idret
Table Cell (td)

Returns

Div
classsIndent
byte[]
Table Row (tr)
idsam
Table Cell (td)

Sample

Div
classsIndent
Code Block
languagejavascript
//export in new byte array
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name']);
//export by adding to templateXLS in default (new) 'Servoy Data' worksheet
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS);
//export by adding to templateXLS, in 'mySheet' worksheet, starting at default(1/1) row/column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet');
//export by adding to templateXLS, in 'mySheet' worksheet, starting at 3rd row and 5th column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet'
,3,5); {code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
,3,5);
Table Row (tr)
classlastDetailRow
Table Cell (td)
 
Table Body (tbody)
idexcelExport-JSFoundSet_StringArray_byteArray_String_Number
}{
Table Row (tr)
:
id
=
name
}{td}h6.excelExport{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)

excelExport

Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}
byte[]
{span}{span:style=
Span
stylefont-weight:
bold;
}
excelExport
{span}{span}\
Span
(foundSet,
dataProviderIds,
templateXLS,
sheetName,
startRow){span}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[JSFoundSet]} foundSet -- the foundset on which to export \{[String]\[]} dataProviderIds -- the ids of the dataproviders \
startRow)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Export to Excel data
Table Row (tr)
idprs
Table Cell (td)

Parameters

Div
classsIndent
{JSFoundSet} foundSet - the foundset on which to export
{String[]} dataProviderIds - the ids of the dataproviders
{byte[]}
templateXLS
-
-
the
xls
template
to
export
in
\

{
[
String
]
}
sheetName
-
-
the
name
of
the
worksheet
\

{
[
Number
]
}
startRow
-
-
row
in
the
foundset
at
which
to
start
the
export {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}byte[]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
export
Table Row (tr)
idret
Table Cell (td)

Returns

Div
classsIndent
byte[]
Table Row (tr)
idsam
Table Cell (td)

Sample

Div
classsIndent
Code Block
languagejavascript
//export in new byte array
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name']);
//export by adding to templateXLS in default (new) 'Servoy Data' worksheet
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS);
//export by adding to templateXLS, in 'mySheet' worksheet, starting at default(1/1) row/column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet');
//export by adding to templateXLS, in 'mySheet' worksheet, starting at 3rd row and 5th column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet',3,5);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)
 
Table Body (tbody)
idexcelExport-JSFoundSet_StringArray_byteArray_String_Number_Number
}{
Table Row (tr)
:
id
=
name
}{td}h6.excelExport{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)

excelExport

Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}
byte[]
{span}{span:style=
Span
stylefont-weight:
bold;
}
excelExport
{span}{span}\
Span
(foundSet,
dataProviderIds,
templateXLS,
sheetName,
startRow,
startColumn)
{span}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[JSFoundSet]} foundSet -- the foundset on which to export \{[String]\[]} dataProviderIds -- the ids of the dataproviders \
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Export to Excel data
Table Row (tr)
idprs
Table Cell (td)

Parameters

Div
classsIndent
{JSFoundSet} foundSet - the foundset on which to export
{String[]} dataProviderIds - the ids of the dataproviders
{byte[]}
templateXLS
-
-
the
xls
template
to
export
in
\

{
[
String
]
}
sheetName
-
-
the
name
of
the
worksheet
\

{
[
Number
]
}
startRow
-
-
row
in
the
foundset
at
which
to
start
the
export
\

{
[
Number
]
}
startColumn
-
-
column
in
the
foundset
at
which
to
start
the
export {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}byte[]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
export
Table Row (tr)
idret
Table Cell (td)

Returns

Div
classsIndent
byte[]
Table Row (tr)
idsam
Table Cell (td)

Sample

Div
classsIndent
Code Block
languagejavascript
//export in new byte array
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name']);
//export by adding to templateXLS in default (new) 'Servoy Data' worksheet
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS);
//export by adding to templateXLS, in 'mySheet' worksheet, starting at default(1/1) row/column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet');
//export by adding to templateXLS, in 'mySheet' worksheet, starting at 3rd row and 5th column
var bytes = plugins.excelxport.excelExport(forms.form1.foundset, ['id','name'],templateXLS, 'mySheet',3,5);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{table}
Table Row (tr)
classlastDetailRow
Table Cell (td)