CreateSubReport

<< Click to Display Table of Contents >>

Manual > Control Reference > Data > Summary report grid control > Method >

CreateSubReport


 

Instructs the summary server to create a sub-report.

 


syntax

CreateSubReport(

         fileType,

         serverOutputFile,

         clientOutputFile,

         summaryName,

         startReferenceDate,

         endReferenceDate,

         groupId,

         pageId,

         startWaitTime,

         waitMode

         [,pageTargetID = 0],

         [,showProgressBar = T]

         [,reportLayoutMaster = ""]

         [,reportLayoutMasterSheet = ""]

         )

 


Parameters

 

fileType


Type:

character


The type of file to output.

"excel" - Excel file

"csv" - CSV file

 

●If the file type is CSV, you can set the detailed format by concatenating the following strings after "csv" with "_" as the separator.

 

example)

"csv"

"csv_header1"

"csv_header1_date[reporttitledateformat]"

"csv_date['%Y/%m/%d %[H+1]:00:00']"

 

・header1

Adds a header. The header name is created based on the field name.

 

・header2

Adds a header. The header name is created based on the report header.

 

・date[summarymaster]

The text in the time column is determined according to the ReportTitleDateFormat in the Summary Master File.

 

・date['%Y/%m/%d %[H+1]:00:00']

・date['@DATETIME']

The characters in the time column will be determined according to the specified format. '%Y/%m/%d You can freely specify the part %[H+1]:00:00'.

For information on the formats that can be specified, please refer to the ReportTitleDateFormat property of the Summary Master.

 

・locale[ja-JP]

Specify the locale. You can specify the ja-JP part freely. If not specified, the locale will follow the OS locale on which the server is running.

 

●If the file type is Excel, you can set the detailed format by concatenating the following strings after "excel" with "_".

 

example)

"excel"

"excel_date['@[%mmonth%d(%a)]']"

"excel_date['@[%mmonth%d(%a)]']_locale[ja-JP]"

"excel_date['@DATETIME.%md.[(%a)]]']_locale[de]"

 

・date[summarymaster]

The text in the time column is determined according to the ReportTitleDateFormat in the Summary Master File.

 

・date['@DATETIME']

The characters in the time column will be determined according to the specified format. You can freely specify the '@DATETIME' part.

For information on the formats that can be specified, please refer to the ReportTitleDateFormat property of the Summary Master.

 

・locale[ja-JP]

Specify the locale. You can specify the ja-JP part freely. If not specified, the locale will follow the OS locale on which the server is running.

When you specify a locale, if there is a report master file "layoutmaster.xls" with the locale character added to the end (e.g. "layoutmaster_ja-JP.xls"), that file will be used. You can separate report master files for each language.

 

 

serverOutputFile


Type:

character


Specify the file name if you want to output a file on the server PC.

 

The file path must be specified as a relative path to the summary folder specified in the summary action. Absolute paths cannot be specified.

 

You can specify the date and time format in the file name, such as "%Y%m%d".

 

If you add a keyword such as [PAGEID] to the file name as shown below, the files will be automatically separated by group, page, etc.

 

Example 1)

CSV\DAY\DAYSUB_[GROUPID2]_[PAGEID2]_

%Y%m%d.csv

 

DAYSUB_1_1_20100312.csv

DAYSUB_1_2_20100312.csv

DAYSUB_2_1_20100312.csv

DAYSUB_2_2_20100312.csv

...

 

Example 2)

CSV\DAY\DAYSUB_[GROUPID]_%Y%m%d.csv

 

DAYSUB_0_20100312.csv

DAYSUB_1_20100312.csv

...

 

The available keywords are:

 

[GROUPID]

:

Group number starting from 0

[GROUPID2]

:

Group number starting from 1

[GROUPNAME]

:

Group Name

[PAGEID]

:

Page number starting from 0

[PAGEID2]

:

1-based page number

[PAGENAME]

:

Page Name

 

 

clientOutputFile


Type:

character


Specify the file name if you want to output a file on the browser PC.

Furthermore, if you specify [ansi] it will be saved in ANSI format, and if you omit it it will be saved in utf8 (with BOM).

 

summaryName


Type:

character


Summary name (aggregated log name) such as DAY/MONTH/YEAR.

 

startReferenceDate


Type:

time


The start reference time for the period of the subreport you want to create.

For details about the reference time, see "ReferenceOffsetSee the " parameter description.

 

endReferenceDate


Type:

time


The end reference time of the period for which you want to create the subreport. The record at the exact end reference time is not included.

For details about the reference time, see "ReferenceOffsetSee the " parameter description.

 

groupId


Type:

Number


Specify the group of reports you want to print using a zero-based index.

-1 - Create all groups

0 or more - Create only the specified groups

 

pageId


Type:

Number


Specifies the page of the report you want to print, using a zero-based index.

-1 - Create all pages

0 or more - Create only the specified pages

 

startWaitTime


Type:

Number


Specify the wait time (msec) before starting creation. Normally, specify 0.

 

waitMode


Type:

character


"wait_true" (or boolean value T): Wait for the method to finish until creation is complete.

"wait_false" (or boolean value F): The method exits immediately without waiting for the creation to finish.

”wait_true_event": Waits for the method to finish until creation is complete. After creation is complete, the OnSummaryNotification(type="createsubreport_done") event occurs.

”wait_false_event": Does not wait for the method to finish until creation is complete. After creation is complete, the OnSummaryNotification(type="createsubreport_done") event will occur.

 

pageTargetID


Type:

Number


0 - Prints the subreport for all pages that match the specified group ID and page ID.

1 - Subreport output according to the value of page property PageTarget1.

2 - Subreport output according to the value of page property PageTarget2.

x - Subreport output according to the value of the page property PageTarge[x].

*For page properties, see SetPageProperty

 

showProgressBar


Type:

Boolean


T - Show progress bar

F - Hide progress bar

 

reportLayoutMaster


Type:

character


The file name of the Layout Master file. If none is specified, the default Layout Master file is used.

 

reportLayoutMasterSheet


Type:

character


Sheet name of the Layout Master File. If none is specified, the default sheet is used.

If a page number is added to the sheet name, specify the sheet name without the "_P1" part, such as "xxx_P1".

Example) Hanko column attached_DAY

 

 

Return Value



Type:

Boolean


FALSE - Failure. TRUE - Success.

 


hmtoggle_plus1Explanation

 


reference