⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 slides.html

📁 永中OFFICE二次开发帮助文档
💻 HTML
📖 第 1 页 / 共 3 页
字号:
 Presentation present = workbook.getPresentations().getActivePresentation(); Slide slide = present.getActiveSlide(); int id = slide.getID(); System.out.println(id); int index = present.getSlides().getSlideIndex(id); System.out.println(index); </pre></DL>
</DD>
</DL>
<HR>

<A NAME="getSlideRange(int[])"><!-- --></A><H3>
getSlideRange</H3>
<PRE>
public <A HREF="../../../../../application/workbooks/workbook/presentations/presentation/SlideRange.html" title="application.workbooks.workbook.presentations.presentation 中的类">SlideRange</A> <B>getSlideRange</B>(int[]&nbsp;slideIndex)</PRE>
<DL>
<DD>根据指定的幻灯片索引值来返回SlideRange对象。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>slideIndex</CODE> - 幻灯片索引值数组
<DT><B>返回:</B><DD>SlideRange对象 <p> <b>例子:</b> <pre> //此样例用于获取索引值为1,2,4 的幻灯片区域 Workbook workbook = Application.getWorkbooks().getActiveWorkbook(); Presentation present = workbook.getPresentations().getActivePresentation(); Slides slides = present.getSlides(); int[]  indexs = new int[]{1,2,4}; SlideRange range = slides.getSlideRange(indexs); Slide[] allSlides = range.getAllSlides(); for (int i = 0; i< allSlides.length;i++) {     System.out.println("index is "+allSlides[i].getSlideIndex()); } </pre></DL>
</DD>
</DL>
<HR>

<A NAME="getSlideRange(application.workbooks.workbook.presentations.presentation.Slide[])"><!-- --></A><H3>
getSlideRange</H3>
<PRE>
public <A HREF="../../../../../application/workbooks/workbook/presentations/presentation/SlideRange.html" title="application.workbooks.workbook.presentations.presentation 中的类">SlideRange</A> <B>getSlideRange</B>(<A HREF="../../../../../application/workbooks/workbook/presentations/presentation/Slide.html" title="application.workbooks.workbook.presentations.presentation 中的类">Slide</A>[]&nbsp;slides)</PRE>
<DL>
<DD>根据指定的幻灯片来返回SlideRange对象。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>slides</CODE> - 幻灯片数组
<DT><B>返回:</B><DD>SlideRange对象 <p> <b>例子:</b> <pre> //此样例用于获取索引值为1,2,4 的幻灯片区域 Workbook workbook = Application.getWorkbooks().getActiveWorkbook(); Presentation present = workbook.getPresentations().getActivePresentation(); Slides slides = present.getSlides(); Slide[] slide = new Slide[3]; slide[0]= slides.getSlide(1); slide[1]= slides.getSlide(2); slide[2]= slides.getSlide(4); SlideRange range = slides.getSlideRange(slide); //打印获取的幻灯片区域内的所有幻灯片的索引值。 Slide[] allSlides = range.getAllSlides(); for (int i = 0; i< allSlides.length;i++) {     System.out.println("index is "+allSlides[i].getSlideIndex()); } </pre></DL>
</DD>
</DL>
<HR>

<A NAME="insertSlide(int)"><!-- --></A><H3>
insertSlide</H3>
<PRE>
public <A HREF="../../../../../application/workbooks/workbook/presentations/presentation/Slide.html" title="application.workbooks.workbook.presentations.presentation 中的类">Slide</A> <B>insertSlide</B>(int&nbsp;index)</PRE>
<DL>
<DD>在指定位置处插入幻灯片。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>index</CODE> - 插入的幻灯片所在的位置
<DT><B>返回:</B><DD>插入的幻灯片<p><b>例子:</b><pre> Workbook workbook = Application.getWorkbooks().getActiveWorkbook(); Presentation present = workbook.getPresentations().getActivePresentation(); Slides slides = present.getSlides(); Slide slide = slides.insertSlide(3);</pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 指定的起始幻灯片索引值小于1或大于幻灯片总数</DL>
</DD>
</DL>
<HR>

<A NAME="paste(int, boolean)"><!-- --></A><H3>
paste</H3>
<PRE>
public void <B>paste</B>(int&nbsp;index,
                  boolean&nbsp;hasFormat)</PRE>
<DL>
<DD>剪切板上的幻灯片粘贴到指定幻灯片索引值位置。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>index</CODE> - 粘贴到的幻灯片索引值位置<DD><CODE>hasFormat</CODE> - 布尔型值,是否带格式。若为true,则带格式;为false,不带格式 <p> <b>例子:</b> <pre> Workbook workbook = Application.getWorkbooks().getActiveWorkbook(); Presentation present = workbook.getPresentations().getActivePresentation(); Slides slides = present.getSlides(); slides.copy(3,5); slides.paste(3,true); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 指定的幻灯片索引值小于1或大于幻灯片总数</DL>
</DD>
</DL>
<HR>

<A NAME="pasteLink(int, boolean)"><!-- --></A><H3>
pasteLink</H3>
<PRE>
public void <B>pasteLink</B>(int&nbsp;index,
                      boolean&nbsp;hasFormat)</PRE>
<DL>
<DD>粘贴链接。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>index</CODE> - 粘贴链接到的幻灯片索引值位置<DD><CODE>hasFormat</CODE> - 布尔型值,是否带格式。如果为true,则带格式粘贴;否则,不带格式粘贴 <p> <b>例子:</b> <pre> Workbook workbook = Application.getWorkbooks().getActiveWorkbook(); Presentation present = workbook.getPresentations().getActivePresentation(); Slides slides = present.getSlides(); slides.copy(3,5); slides.pasteLink(3,true); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 指定的起始幻灯片索引值小于1或大于幻灯片总数</DL>
</DD>
</DL>
<HR>

<A NAME="pasteSpecial(int, int, int)"><!-- --></A><H3>
pasteSpecial</H3>
<PRE>
public void <B>pasteSpecial</B>(int&nbsp;index,
                         int&nbsp;type,
                         int&nbsp;operation)</PRE>
<DL>
<DD>选择性粘贴幻灯片。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>index</CODE> - 选择性粘贴到的幻灯片索引值位置<DD><CODE>type</CODE> - 粘贴类型 <pre> 0 - 粘贴 1 - 粘贴链接 </pre><DD><CODE>operation</CODE> - 操作符类型 <pre> 0 - 未格式化文本 1 - 格式化文本 2 - 图片 3 - 幻灯片对象 </pre> <p> <b>例子:</b> <pre> Workbook workbook = Application.getWorkbooks().getActiveWorkbook(); Presentation present = workbook.getPresentations().getActivePresentation(); Slides slides = present.getSlides(); slides.copy(3,5); slides.pasteSpecial(3,0,3); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 指定的起始幻灯片索引值小于1或大于幻灯片总数
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 粘贴类型不是已知类型
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 操作符类型不是已知类型</DL>
</DD>
</DL>
<HR>

<A NAME="removeSlide(int)"><!-- --></A><H3>
removeSlide</H3>
<PRE>
public void <B>removeSlide</B>(int&nbsp;index)</PRE>
<DL>
<DD>删除幻灯片。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>index</CODE> - 幻灯片索引值<p><b>例子:</b><pre> Workbook workbook = Application.getWorkbooks().getActiveWorkbook(); Presentation present = workbook.getPresentations().getActivePresentation(); Slides slides = present.getSlides(); slides.removeSlide(3);</pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 指定的起始幻灯片索引值小于1或大于幻灯片总数</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>


<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="跳过导航链接"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>概述</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>软件包</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>类</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>树</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>索引</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>帮助</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../../application/workbooks/workbook/presentations/presentation/SlideRange.html" title="application.workbooks.workbook.presentations.presentation 中的类"><B>上一个类</B></A>&nbsp;
&nbsp;下一个类</FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../../index.html?application/workbooks/workbook/presentations/presentation/Slides.html" target="_top"><B>框架</B></A>  &nbsp;
&nbsp;<A HREF="Slides.html" target="_top"><B>无框架</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>所有类</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../../../../allclasses-noframe.html"><B>所有类</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  摘要:&nbsp;嵌套&nbsp;|&nbsp;字段&nbsp;|&nbsp;构造方法&nbsp;|&nbsp;<A HREF="#method_summary">方法</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
详细信息:&nbsp;字段&nbsp;|&nbsp;构造方法&nbsp;|&nbsp;<A HREF="#method_detail">方法</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->

<HR>
版权所有 2001-2006 无锡永中科技有限公司
</BODY>
</HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -