このページの翻訳は最新ではありません。ここをクリックして、英語の最新版を参照してください。
mlreportgen.report.TitlePage.createTemplate
クラス: mlreportgen.report.TitlePage
パッケージ: mlreportgen.report
タイトル ページ テンプレートの作成
構文
template = mlreportgen.report.TitlePage.createTemplate(templatePath,type)
説明
は、template
= mlreportgen.report.TitlePage.createTemplate(templatePath
,type
)templatePath
で指定された場所に、type
で指定された既定のタイトル ページ レポーター テンプレートのコピーを作成します。コピーしたテンプレートを開始点として使用して、レポート用のカスタム タイトル ページ テンプレートを設計できます。
入力引数
出力引数
例
タイトル ページ テンプレートの作成
この例を実行する前に、mytemplates
フォルダーに既定の HTML TitlePage
テンプレートのコピーを作成します。コピーしたテンプレートに myTitlePg.htmtx
という名前を付けます。必要に応じてテンプレートを編集します。タイトル ページ用の新しいテンプレートを使用するには、そのパスを TitlePage
の TemplateSrc
プロパティに割り当てます。
import mlreportgen.report.* rpt = Report('My Report','html'); tp = TitlePage(); tp.Title = 'Data Summary'; template = TitlePage.createTemplate('mytemplates\myTitlePg','html'); tp.TemplateSrc = template;
バージョン履歴
R2017b で導入