Class Presentation

顯示內容

簡報。

方法

方法傳回類型簡短說明
addEditor(emailAddress)Presentation將指定使用者新增至 Presentation 的編輯者清單。
addEditor(user)Presentation將指定使用者新增至 Presentation 的編輯者清單。
addEditors(emailAddresses)Presentation將指定的使用者陣列新增至 Presentation 的編輯者清單。
addViewer(emailAddress)Presentation將指定使用者新增至 Presentation 的檢視者清單。
addViewer(user)Presentation將指定使用者新增至 Presentation 的檢視者清單。
addViewers(emailAddresses)Presentation將指定的使用者陣列新增至 Presentation 的檢視者清單。
appendSlide()Slide使用根據目前母片預先定義的版面配置,將投影片附加至簡報結尾。PredefinedLayout.BLANK
appendSlide(layout)Slide根據目前的母片,使用指定版面配置將投影片附加至簡報結尾。
appendSlide(predefinedLayout)Slide根據目前的母片,使用指定的預先定義版面配置,在簡報結尾附加投影片。
appendSlide(slide)Slide將提供的 Slide 副本附加到簡報結尾。
appendSlide(slide, linkingMode)Slide將來源簡報中提供的 Slide 副本附加到目前簡報的結尾,並根據 SlideLinkingMode 設定投影片連結。
getEditors()User[]取得這個 Presentation 的編輯者清單。
getId()String取得簡報的專屬 ID。
getLayouts()Layout[]取得簡報中的版面配置。
getMasters()Master[]取得簡報中的主投影片。
getName()String取得簡報的名稱或標題。
getNotesMaster()NotesMaster取得簡報的備忘稿母片。
getNotesPageHeight()Number以點為單位,取得簡報中備忘稿母片和備忘稿頁面的頁面高度。
getNotesPageWidth()Number以點為單位,取得簡報中備忘稿母片和備忘稿頁面的頁面寬度。
getPageElementById(id)PageElement|null傳回具有指定 ID 的 PageElement,或如果不存在,則傳回 null
getPageHeight()Number以點為單位,取得簡報中投影片、版面配置和母片的頁面高度。
getPageWidth()Number以點為單位,取得簡報中投影片、版面配置和母片的頁面寬度。
getSelection()Selection|null取得使用者的選取項目 (使用中的簡報)。
getSlideById(id)Slide|null傳回具有指定 ID 的 Slide,或如果不存在,則傳回 null
getSlides()Slide[]取得簡報中的投影片。
getUrl()String擷取存取這份簡報的網址。
getViewers()User[]取得這個 Presentation 的檢視者和加註者清單。
insertSlide(insertionIndex)Slide使用根據目前主投影片的 PredefinedLayout.BLANK 預先定義版面配置,在簡報中指定索引處插入投影片。
insertSlide(insertionIndex, layout)Slide使用目前的主投影片,根據指定的版面配置,在簡報中指定索引處插入投影片。
insertSlide(insertionIndex, predefinedLayout)Slide使用目前母片中指定的預先定義版面配置,在簡報中指定索引處插入投影片。
insertSlide(insertionIndex, slide)Slide在簡報中指定索引處插入提供的 Slide 副本。
insertSlide(insertionIndex, slide, linkingMode)Slide將來源簡報中提供的 Slide 副本插入目前簡報的指定索引,並根據 SlideLinkingMode 設定投影片連結。
removeEditor(emailAddress)PresentationPresentation 的編輯者清單中移除指定使用者。
removeEditor(user)PresentationPresentation 的編輯者清單中移除指定使用者。
removeViewer(emailAddress)PresentationPresentation 的觀眾和留言者清單中移除指定使用者。
removeViewer(user)PresentationPresentation 的觀眾和留言者清單中移除指定使用者。
replaceAllText(findText, replaceText)Integer將所有符合「尋找文字」的文字例項替換為「取代文字」。
replaceAllText(findText, replaceText, matchCase)Integer將所有符合「尋找文字」的文字例項替換為「取代文字」。
saveAndClose()void儲存目前的 Presentation
setName(name)void設定簡報名稱或標題。

內容詳盡的說明文件

addEditor(emailAddress)

將指定使用者新增至 Presentation 的編輯者清單。如果使用者已在觀眾名單中,這個方法會將使用者從觀眾名單中移除。

參數

名稱類型說明
emailAddressString要新增的使用者電子郵件地址。

回攻員

Presentation - This Presentation,用於鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

addEditor(user)

將指定使用者新增至 Presentation 的編輯者清單。如果使用者已在觀眾名單中,這個方法會將使用者從觀眾名單中移除。

參數

名稱類型說明
userUser要新增的使用者代表。

回攻員

Presentation - This Presentation,用於鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

addEditors(emailAddresses)

將指定的使用者陣列新增至 Presentation 的編輯者清單。如果使用者已在觀眾名單中,這個方法會將他們從觀眾名單中移除。

參數

名稱類型說明
emailAddressesString[]要新增的使用者電子郵件地址陣列。

回攻員

Presentation - This Presentation,用於鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

addViewer(emailAddress)

將指定使用者新增至 Presentation 的檢視者清單。如果使用者已在編輯者名單中,這個方法不會有任何作用。

參數

名稱類型說明
emailAddressString要新增的使用者電子郵件地址。

回攻員

Presentation - This Presentation,用於鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

addViewer(user)

將指定使用者新增至 Presentation 的檢視者清單。如果使用者已在編輯者名單中,這個方法不會有任何作用。

參數

名稱類型說明
userUser要新增的使用者代表。

回攻員

Presentation - This Presentation,用於鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

addViewers(emailAddresses)

將指定的使用者陣列新增至 Presentation 的檢視者清單。如果使用者已在編輯者清單中,這個方法對他們不會有任何影響。

參數

名稱類型說明
emailAddressesString[]要新增的使用者電子郵件地址陣列。

回攻員

Presentation - This Presentation,用於鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

appendSlide()

使用目前的母片,根據預先定義的版面配置,在簡報結尾附加投影片。PredefinedLayout.BLANK目前的母項是下列其中一項:

  • 目前最後一張投影片的母片。
  • 簡報中的第一個母片 (如果沒有投影片)。

回攻員

Slide:附加的新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

appendSlide(layout)

根據目前的母片,使用指定版面配置將投影片附加至簡報結尾。目前的母項是下列其中一項:

  • 目前最後一張投影片的母片。
  • 簡報中的第一個母片 (如果沒有投影片)。

參數

名稱類型說明
layoutLayout新投影片要使用的版面配置,應位於目前的母片中。

回攻員

Slide:附加的新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

appendSlide(predefinedLayout)

根據目前的母片,使用指定的預先定義版面配置,在簡報結尾附加投影片。目前的母項是下列其中一項:

  • 目前最後一張投影片的母片。
  • 簡報中的第一個母片 (如果沒有投影片)。

參數

名稱類型說明
predefinedLayoutPredefinedLayout新投影片要使用的預先定義版面配置,應位於目前的主版中。

回攻員

Slide:附加的新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

appendSlide(slide)

在簡報結尾附加所提供 Slide 的副本。

如果複製的投影片來自其他簡報,且該簡報中沒有上層母片和版面配置頁面,系統也會一併複製。

// Copy a slide from another presentation and appends it.
const otherPresentation = SlidesApp.openById('presentationId');
const currentPresentation = SlidesApp.getActivePresentation();
const slide = otherPresentation.getSlides()[0];
currentPresentation.appendSlide(slide);

參數

名稱類型說明
slideSlide要複製及附加的投影片。

回攻員

Slide:附加的新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

appendSlide(slide, linkingMode)

將來源簡報中提供的 Slide 副本附加到目前簡報的結尾,並根據 SlideLinkingMode 設定投影片連結。

如果複製的投影片來自其他簡報,且目前簡報中沒有上層母片和版面配置頁面,系統也會一併複製。

如果連結模式為 SlideLinkingMode.LINKED,當呼叫 Slide.refreshSlide() 時,附加的投影片可以更新為與提供的來源投影片相符。其他協作者則會看到來源投影片的連結。SlideLinkingMode.LINKED 無法與目前簡報的來源投影片搭配使用。

// Copy a slide from another presentation, then append and link it.
const sourcePresentation = SlidesApp.openById('presentationId');
const currentPresentation = SlidesApp.getActivePresentation();
const slide = sourcePresentation.getSlides()[0];
const appendedSlide = currentPresentation.appendSlide(
    slide,
    SlidesApp.SlideLinkingMode.LINKED,
);

參數

名稱類型說明
slideSlide要複製、附加及連結的投影片。
linkingModeSlideLinkingMode要使用的連結模式。

回攻員

Slide:新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getEditors()

取得這個 Presentation 的編輯者清單。

回攻員

User[]:具有編輯權限的使用者陣列。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getId()

取得簡報的專屬 ID。簡報 ID 會與 SlidesApp.openById() 搭配使用,開啟特定簡報例項。

回攻員

String:這份簡報的 ID。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getLayouts()

取得簡報中的版面配置。

回攻員

Layout[]:這份簡報中的版面配置清單。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getMasters()

取得簡報中的主投影片。

回攻員

Master[]:這份簡報中的主投影片清單。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getName()

取得簡報的名稱或標題。

回攻員

String - 這份簡報的標題。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getNotesMaster()

取得簡報的備忘稿母片。

回攻員

NotesMaster:簡報的備忘稿母片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getNotesPageHeight()

以點為單位,取得簡報中備忘稿母片和備忘稿頁面的高度。所有頁面的高度都相同。

回攻員

Number:附註頁面的高度 (以點為單位)。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getNotesPageWidth()

以點為單位,取得簡報中備忘稿母片和備忘稿頁面的頁面寬度。這些頁面的寬度都相同。

回攻員

Number:附註頁面的寬度 (以點為單位)。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getPageElementById(id)

傳回具有指定 ID 的 PageElement,或如果不存在,則傳回 null

參數

名稱類型說明
idString要擷取的網頁元素 ID。

回攻員

PageElement|null:具有指定 ID 的頁面元素。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getPageHeight()

以點為單位,取得簡報中投影片、版面配置和母片的頁面高度。所有頁面的高度都相同。

回攻員

Number:頁面高度 (以點為單位)。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getPageWidth()

以點為單位,取得簡報中投影片、版面配置和母片的頁面寬度。這些頁面的寬度都相同。

回攻員

Number:頁面寬度 (以點為單位)。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getSelection()

取得使用者的選取項目 (使用中的簡報)。指令碼只能存取執行指令碼的使用者選取的內容,且指令碼必須繫結至簡報。

請注意,傳回的選取項目是目前有效的選取項目。由於指令碼會對簡報進行各種變更,選取範圍也會隨之轉換,以納入這些變更。舉例來說,如果選取兩個形狀 A 和 B,然後指令碼移除形狀 B,傳回的選取物件會隱含更新,只選取形狀 A。

// Gets the current active page that is selected in the active presentation.
const selection = SlidesApp.getActivePresentation().getSelection();
const currentPage = selection.getCurrentPage();

回攻員

Selection|null:代表使用者選取的項目,如果指令碼未繫結至簡報,或沒有有效的使用者選取項目,則為 null

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getSlideById(id)

傳回具有指定 ID 的 Slide,或如果不存在,則傳回 null

參數

名稱類型說明
idString要擷取的投影片 ID。

回攻員

Slide|null - 具有指定 ID 的投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getSlides()

取得簡報中的投影片。

回攻員

Slide[]:這份簡報中的投影片清單。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getUrl()

擷取存取這份簡報的網址。

const presentation = SlidesApp.getActivePresentation();

// Send out the link to open the presentation.
MailApp.sendEmail(
    '<email-address>',
    presentation.getName(),
    presentation.getUrl(),
);

回攻員

String:存取目前簡報的網址。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

getViewers()

取得這個 Presentation 的檢視者和加註者清單。

回攻員

User[]:具有檢視或留言權限的使用者陣列。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

insertSlide(insertionIndex)

使用根據目前主投影片的 PredefinedLayout.BLANK 預先定義版面配置,在簡報中指定索引處插入投影片。目前的控制台是下列其中一個:

  • 上一張投影片的母片。
  • 如果 insertionIndex 為零,則為第一張投影片的母片。
  • 簡報中的第一個母片 (如果沒有投影片)。

參數

名稱類型說明
insertionIndexInteger從零開始的索引,指出要插入投影片的位置。

回攻員

Slide:插入的新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

insertSlide(insertionIndex, layout)

使用目前的主投影片,根據指定的版面配置,在簡報中指定索引處插入投影片。目前的母項是下列其中一項:

  • 上一張投影片的母片。
  • 如果 insertionIndex 為零,則為第一張投影片的母片。
  • 簡報中的第一個母片 (如果沒有投影片)。

參數

名稱類型說明
insertionIndexInteger從零開始的索引,指出要插入投影片的位置。
layoutLayout新投影片要使用的版面配置,應位於目前的母片中。

回攻員

Slide:插入的新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

insertSlide(insertionIndex, predefinedLayout)

使用目前主投影片中指定的預先定義版面配置,在簡報中指定索引處插入投影片。目前的母項是下列其中一項:

  • 上一張投影片的母片。
  • 如果 insertionIndex 為零,則為第一張投影片的母片。
  • 簡報中的第一個母片 (如果沒有投影片)。

參數

名稱類型說明
insertionIndexInteger從零開始的索引,指出要插入投影片的位置。
predefinedLayoutPredefinedLayout新投影片要使用的預先定義版面配置,應位於目前的主版中。

回攻員

Slide:插入的新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

insertSlide(insertionIndex, slide)

在簡報中指定索引處插入提供的 Slide 副本。

如果複製的投影片來自其他簡報,且該簡報中沒有上層母片和版面配置頁面,系統也會一併複製。

// Copy a slide from another presentation and inserts it.
const otherPresentation = SlidesApp.openById('presentationId');
const currentPresentation = SlidesApp.getActivePresentation();
const slide = otherPresentation.getSlides()[0];
const insertionIndex = 1;
currentPresentation.insertSlide(insertionIndex, slide);

參數

名稱類型說明
insertionIndexInteger從零開始的索引,指出要插入投影片的位置。
slideSlide要複製及插入的投影片。

回攻員

Slide:插入的新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

insertSlide(insertionIndex, slide, linkingMode)

將來源簡報中提供的 Slide 副本插入目前簡報的指定索引,並根據 SlideLinkingMode 設定投影片連結。

如果複製的投影片來自其他簡報,且目前簡報中沒有上層母片和版面配置頁面,系統也會一併複製。

如果連結模式為 SlideLinkingMode.LINKED,當系統呼叫 Slide.refreshSlide() 時,插入的投影片可以更新為與提供的來源投影片相符。其他協作者可以查看來源投影片的連結。SlideLinkingMode.LINKED 無法與目前簡報的來源投影片搭配使用。

// Copy a slide from another presentation, then insert and link it.
const sourcePresentation = SlidesApp.openById('presentationId');
const currentPresentation = SlidesApp.getActivePresentation();
const slide = sourcePresentation.getSlides()[0];
const insertionIndex = 1;
const insertedSlide = currentPresentation.insertSlide(
    insertionIndex,
    slide,
    SlidesApp.SlideLinkingMode.LINKED,
);

參數

名稱類型說明
insertionIndexInteger從零開始的索引,指出要插入投影片的位置。
slideSlide要複製及插入的投影片。
linkingModeSlideLinkingMode要使用的連結模式。

回攻員

Slide:新投影片。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

removeEditor(emailAddress)

Presentation 的編輯者清單中移除指定使用者。如果使用者屬於具有一般存取權的使用者類別,例如 Presentation 是與使用者的整個網域共用,或是 Presentation 位於使用者可存取的共用雲端硬碟中,這個方法就無法禁止使用者存取 Presentation

如果是雲端硬碟檔案,系統也會從檢視者清單中移除該使用者。

參數

名稱類型說明
emailAddressString要移除的使用者電子郵件地址。

回攻員

Presentation - This Presentation,用於鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

removeEditor(user)

Presentation 的編輯者清單中移除指定使用者。如果使用者屬於具有一般存取權的使用者類別,例如 Presentation 是與使用者的整個網域共用,或是 Presentation 位於使用者可存取的共用雲端硬碟中,這個方法就無法禁止使用者存取 Presentation

如果是雲端硬碟檔案,系統也會從檢視者清單中移除該使用者。

參數

名稱類型說明
userUser要移除的使用者代表。

回攻員

Presentation - This Presentation,用於鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

removeViewer(emailAddress)

Presentation 的觀眾和留言者清單中移除指定使用者。如果使用者是編輯者,而非檢視者或留言者,這個方法不會有任何作用。如果使用者屬於具有一般存取權的使用者類別 (例如 Presentation 與使用者的整個網域共用,或 Presentation 位於使用者可存取的共用雲端硬碟中),這個方法也無法禁止使用者存取 Presentation

如果是雲端硬碟檔案,系統也會從編輯者清單中移除使用者。

參數

名稱類型說明
emailAddressString要移除的使用者電子郵件地址。

回攻員

Presentation - 這是 Presentation 的鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

removeViewer(user)

Presentation 的觀眾和留言者清單中移除指定使用者。如果使用者是編輯者而非檢視者,這個方法不會生效。如果使用者屬於具有一般存取權的使用者類別 (例如 Presentation 與使用者的整個網域共用,或 Presentation 位於使用者可存取的共用雲端硬碟中),這個方法也無法禁止使用者存取 Presentation

如果是雲端硬碟檔案,系統也會從編輯者清單中移除使用者。

參數

名稱類型說明
userUser要移除的使用者代表。

回攻員

Presentation - 這是 Presentation 的鏈結。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

replaceAllText(findText, replaceText)

將所有符合「尋找文字」的文字例項替換為「取代文字」。搜尋時不區分大小寫。

參數

名稱類型說明
findTextString要尋找的文字。
replaceTextString要用來取代相符文字的文字。

回攻員

Integer - 發生次數已變更

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

replaceAllText(findText, replaceText, matchCase)

將所有符合「尋找文字」的文字例項替換為「取代文字」。

參數

名稱類型說明
findTextString要尋找的文字。
replaceTextString要用來取代相符文字的文字。
matchCaseBoolean如果顯示 true,搜尋時會區分大小寫;如果顯示 false,搜尋時不會區分大小寫。

回攻員

Integer - 發生次數已變更

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

saveAndClose()

儲存目前的 Presentation。導致待處理的更新遭到清除並套用。

即使指令碼執行因錯誤而終止,系統也會在每個開啟的 Presentation 指令碼執行結束時,自動叫用 saveAndClose() 方法。

已關閉的 Presentation 無法編輯。使用 SlidesApp 的其中一種開啟方法,重新開啟特定簡報進行編輯。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations

setName(name)

設定簡報名稱或標題。

參數

名稱類型說明
nameString要為這份簡報設定的名稱。

授權

使用這個方法的指令碼需要一或多個下列範圍的授權:

  • https://www.googleapis.com/auth/presentations.currentonly
  • https://www.googleapis.com/auth/presentations