Word.SelectionMode enum

この列挙型は、文書内のカーソル (カーソル) が選択範囲の後にある場所を設定します。

注釈

[ API セット: WordApi 1.1 ]

// Link to full sample: https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/word/35-ranges/scroll-to-range.yaml

await Word.run(async (context) => {
  // Select can be at the start or end of a range; this by definition moves the insertion point without selecting the range.
  context.document.body.paragraphs.getLast().select(Word.SelectionMode.end);

  await context.sync();
});

フィールド

end = "End"

カーソルは選択範囲の末尾 (選択した範囲の末尾のすぐ後) にあります。

select = "Select"

範囲全体が選択されています。

start = "Start"

カーソルは選択範囲の先頭 (選択した範囲の開始直前) にあります。