Word.PaperSize enum

用紙サイズを指定します。

注釈

API セット: WordApiDesktop 1.3

使用元

// Link to full sample: https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/word/50-document/manage-section-starts.yaml

await Word.run(async (context) => {

  // Configure document-wide page settings for a report that will be printed and bound.
  const pageSetup: Word.PageSetup = context.document.pageSetup;
  pageSetup.set({
    paperSize: Word.PaperSize.letter,
    orientation: Word.PageOrientation.portrait,
    topMargin: 72,
    bottomMargin: 72,
    leftMargin: 90,
    rightMargin: 72,
    gutter: 18,
    gutterPosition: Word.GutterPosition.left,
    mirrorMargins: true,
    oddAndEvenPagesHeaderFooter: true
  });

  const sections: Word.SectionCollection = context.document.sections;
  sections.load("items");
  await context.sync();

  // Start the main chapter on an odd-numbered page so it appears on the right in a bound document.
  const chapterPageSetup: Word.PageSetup = sections.items[1].pageSetup;
  chapterPageSetup.sectionStart = Word.SectionStart.oddPage;
  chapterPageSetup.differentFirstPageHeaderFooter = true;

  // Keep the appendix in a separate section, but let it begin on the current page.
  sections.items[2].pageSetup.sectionStart = Word.SectionStart.continuous;

  await context.sync();
  console.log("Applied print and binding settings to the report.");
});

フィールド

a3 = "A3"

A3 用紙サイズ。

a4 = "A4"

A4 用紙サイズ。

a4Small = "A4Small"

小さな A4 用紙サイズ。

a5 = "A5"

A5 用紙サイズ。

b4 = "B4"

B4 用紙サイズ。

b5 = "B5"

B5 用紙サイズ。

csheet = "CSheet"

C シートの用紙サイズ。

custom = "Custom"

ユーザー設定の用紙サイズ

dsheet = "DSheet"

D シートの用紙サイズ。

envelope10 = "Envelope10"

封筒サイズ 10。

envelope11 = "Envelope11"

封筒サイズ 11。

envelope12 = "Envelope12"

封筒サイズ 12。

envelope14 = "Envelope14"

封筒サイズ 14.

envelope9 = "Envelope9"

封筒サイズ 9。

envelopeB4 = "EnvelopeB4"

封筒 B4 サイズ。

envelopeB5 = "EnvelopeB5"

封筒 B5 サイズ。

envelopeB6 = "EnvelopeB6"

封筒 B6 サイズ。

envelopeC3 = "EnvelopeC3"

封筒 C3 サイズ。

envelopeC4 = "EnvelopeC4"

封筒 C4 サイズ。

envelopeC5 = "EnvelopeC5"

封筒 C5 サイズ。

envelopeC6 = "EnvelopeC6"

封筒 C6 サイズ。

envelopeC65 = "EnvelopeC65"

封筒C65サイズ。

envelopeDL = "EnvelopeDL"

エンベロープ DL サイズ。

envelopeItaly = "EnvelopeItaly"

封筒イタリア サイズ

envelopeMonarch = "EnvelopeMonarch"

封筒モナーク サイズ

envelopePersonal = "EnvelopePersonal"

封筒 個人用サイズ。

esheet = "ESheet"

電子シートの用紙サイズ。

executive = "Executive"

エグゼクティブ用紙サイズ。

fanfoldLegalGerman = "FanfoldLegalGerman"

ファンフォールドの合法的なドイツ紙サイズ。

fanfoldStdGerman = "FanfoldStdGerman"

ファンフォールドの標準ドイツ紙サイズ。

fanfoldUS = "FanfoldUS"

Fanfold US 用紙サイズ。

folio = "Folio"

フォリオ用紙サイズ。

ledger = "Ledger"

元帳の用紙サイズ。

legal = "Legal"

リーガル用紙サイズ。

letter = "Letter"

レター用紙のサイズ。

letterSmall = "LetterSmall"

小さい便紙サイズ。

note = "Note"

ノート用紙サイズ。

quarto = "Quarto"

Quarto の用紙サイズ。

size10x14 = "Size10x14"

10x14 の用紙サイズ。

size11x17 = "Size11x17"

11 x 17 の用紙サイズ。

statement = "Statement"

ステートメント用紙サイズ。

tabloid = "Tabloid"

タブロイド紙のサイズ。