📄 footnoteoptions.html
字号:
Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); BaseText baseText = section.getBaseText(); baseText.insertText(0,"this is a test!\n this is a test!\n this is a test!"); FootNoteOptions footNoteOptions = baseText.getFootNoteOptions(10); System.out.println("返回脚注的编号格式:"+footNoteOptions.getNumberStyle()); </pre></DL>
</DD>
</DL>
<HR>
<A NAME="getPosition()"><!-- --></A><H3>
getPosition</H3>
<PRE>
public int <B>getPosition</B>()</PRE>
<DL>
<DD>得到脚注的位置。
<P>
<DD><DL>
<DT><B>返回:</B><DD>脚注的位置,只能取以下值之一: <pre> NoteConstants.BELLOW_PAGE = 0; 脚注在页面底端 NoteConstants.BELLOW_WORD = 1; 脚注在文字下面 </pre> <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); BaseText baseText = section.getBaseText(); baseText.insertText(0,"this is a test!\n this is a test!\n this is a test!"); FootNoteOptions footNoteOptions = baseText.getFootNoteOptions(10); System.out.println("返回脚注的位置:"+footNoteOptions.getPosition()); </pre></DL>
</DD>
</DL>
<HR>
<A NAME="getStartingNumber()"><!-- --></A><H3>
getStartingNumber</H3>
<PRE>
public int <B>getStartingNumber</B>()</PRE>
<DL>
<DD>得到脚注的起始编号。
<P>
<DD><DL>
<DT><B>返回:</B><DD>起始编号 <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); BaseText baseText = section.getBaseText(); baseText.insertText(0,"this is a test!\n this is a test!\n this is a test!"); FootNoteOptions footNoteOptions = baseText.getFootNoteOptions(10); System.out.println("返回脚注的起始编号:"+footNoteOptions.getStartingNumber()); </pre></DL>
</DD>
</DL>
<HR>
<A NAME="setNumberRule(int)"><!-- --></A><H3>
setNumberRule</H3>
<PRE>
public void <B>setNumberRule</B>(int numberRule)</PRE>
<DL>
<DD>设置脚注的编号方式。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>numberRule</CODE> - 编号方式,只能取以下值之一: <pre> NoteConstants.NUMBER_CONTINUE = 0; 编号方式为连续编号 NoteConstants.NUMBER_SECTION_START = 1; 编号方式为每节重新编号 NoteConstants.NUMBER_PAGE_START = 2; 编号方式为每页重新编号 </pre> <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); BaseText baseText = section.getBaseText(); baseText.insertText(0,"this is a test!\n this is a test!\n this is a test!"); FootNoteOptions footNoteOptions = baseText.getFootNoteOptions(10); footNoteOptions.setCustomSymbol(null); footNoteOptions.setNumberStyle(NoteConstants.NUMBER_UPPER_ROMAN); baseText.addFootNote(10, 2); footNoteOptions.setNumberRule(NoteConstants.NUMBER_PAGE_START); doc.insertBreak(15,BreakConstants.BREAK_PAGE); long secondOffset = baseText.getTextLength()-1; baseText.insertText(secondOffset,"second page"); baseText.addFootNote(secondOffset, 2); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当脚注的编号方式常量不存在<DT><B>另请参见:</B><DD><A HREF="../../../../../application/workbooks/workbook/documents/document/section/FootNote.html" title="application.workbooks.workbook.documents.document.section 中的类"><CODE>FootNote</CODE></A></DL>
</DD>
</DL>
<HR>
<A NAME="setNumberStyle(int)"><!-- --></A><H3>
setNumberStyle</H3>
<PRE>
public void <B>setNumberStyle</B>(int index)</PRE>
<DL>
<DD>设置脚注的编号格式。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>index</CODE> - 编号格式的索引,只能取以下值之一: <pre> NoteConstants.NUMBER_DECIMAL 编号格式为“1,2,3,...” NoteConstants.NUMBER_SBC_CASE 编号格式为“全角” NoteConstants.NUMBER_UPPER_ALPHA 编号格式为“A,B,C,...” NoteConstants.NUMBER_LOWER_ALPHA 编号格式为“a,b,c,...” NoteConstants.NUMBER_LOWER_ROMAN 编号格式为“i,ii,iii,...” NoteConstants.NUMBER_UPPER_ROMAN 编号格式为“I,II,III,...” NoteConstants.NUMBER_UPPER_CHINA 编号格式为“壹,贰,叁,...” NoteConstants.NUMBER_TRADITION_LOWER_CHINA 编号格式为“一,二,三,...(繁)” NoteConstants.NUMBER_SIMPLE_LOWER_CHINA 编号格式为“一,二,三,...(简)” NoteConstants.NUMBER_UPPER_CHINA1 编号格式为"壹,貳,參 …" NoteConstants.NUMBER_EAVEN 编号格式为“甲,乙,丙,...” NoteConstants.NUMBER_EATH 编号格式为“子,丑,寅,...” NoteConstants.NUMBER_CIRCLE 编号格式为“圈内数字” NoteConstants.NUMBER_BRACKET 编号格式为“括号数字” </pre> <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); BaseText baseText = section.getBaseText(); baseText.insertText(0,"this is a test!\n this is a test!\n this is a test!"); FootNoteOptions footNoteOptions = baseText.getFootNoteOptions(10); footNoteOptions.setCustomSymbol(null); footNoteOptions.setNumberStyle(NoteConstants.NUMBER_UPPER_ROMAN); baseText.addFootNote(10, 2); </pre>
<DT><B>抛出:</B>
<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> - 当编号格式的索引常量不存在<DT><B>另请参见:</B><DD><A HREF="../../../../../application/constants/NoteConstants.html" title="application.constants 中的接口"><CODE>NoteConstants</CODE></A>,
<A HREF="../../../../../application/workbooks/workbook/documents/document/section/FootNote.html" title="application.workbooks.workbook.documents.document.section 中的类"><CODE>FootNote</CODE></A></DL>
</DD>
</DL>
<HR>
<A NAME="setPosition(int)"><!-- --></A><H3>
setPosition</H3>
<PRE>
public void <B>setPosition</B>(int position)</PRE>
<DL>
<DD>设置脚注的位置。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>position</CODE> - 脚注的位置,只能取以下值之一: <pre> NoteConstants.BELLOW_PAGE = 0; 脚注在页面底端 NoteConstants.BELLOW_WORD = 1; 脚注在文字下面 </pre> <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); BaseText baseText = section.getBaseText(); baseText.insertText(0,"this is a test!\n this is a test!\n this is a test!"); FootNoteOptions footNoteOptions = baseText.getFootNoteOptions(10); footNoteOptions.setPosition(NoteConstants.BELLOW_WORD); baseText.addFootNote(10, 2); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当脚注的位置常量不存在<DT><B>另请参见:</B><DD><A HREF="../../../../../application/workbooks/workbook/documents/document/section/FootNote.html" title="application.workbooks.workbook.documents.document.section 中的类"><CODE>FootNote</CODE></A></DL>
</DD>
</DL>
<HR>
<A NAME="setStartingNumber(int)"><!-- --></A><H3>
setStartingNumber</H3>
<PRE>
public void <B>setStartingNumber</B>(int startingNumber)</PRE>
<DL>
<DD>设置脚注的起始编号。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>startingNumber</CODE> - 起始编号 <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); BaseText baseText = section.getBaseText(); baseText.insertText(0,"this is a test!\n this is a test!\n this is a test!"); FootNoteOptions footNoteOptions = baseText.getFootNoteOptions(10); footNoteOptions.setCustomSymbol(null); footNoteOptions.setNumberStyle(NoteConstants.NUMBER_UPPER_ROMAN); footNoteOptions.setStartingNumber(5); baseText.addFootNote(10, 2); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当脚注的起始编号小于1<DT><B>另请参见:</B><DD><A HREF="../../../../../application/workbooks/workbook/documents/document/section/FootNote.html" title="application.workbooks.workbook.documents.document.section 中的类"><CODE>FootNote</CODE></A></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> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>软件包</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>类</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>树</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>索引</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>帮助</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../application/workbooks/workbook/documents/document/FindResult.html" title="application.workbooks.workbook.documents.document 中的类"><B>上一个类</B></A>
<A HREF="../../../../../application/workbooks/workbook/documents/document/GridSettings.html" title="application.workbooks.workbook.documents.document 中的类"><B>下一个类</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../index.html?application/workbooks/workbook/documents/document/FootNoteOptions.html" target="_top"><B>框架</B></A>
<A HREF="FootNoteOptions.html" target="_top"><B>无框架</B></A>
<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">
摘要: 嵌套 | 字段 | 构造方法 | <A HREF="#method_summary">方法</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
详细信息: 字段 | 构造方法 | <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 + -