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

📄 barcodeinfo.html

📁 永中OFFICE二次开发帮助文档
💻 HTML
📖 第 1 页 / 共 4 页
字号:

<DT><B>返回:</B><DD>发布层次 <pre> 0    省军级 1    市地师级 2    县团级 3    公开发布 4    特定范围 </pre> <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setTelegraphLevel(2);  attr.setDate("20051201");  attr.setProductLevel(1);  barcode.setBarcodeInfo(attr);    barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode);  System.out.println("发布层次: "+attr.getProductLevel()); </pre></DL>
</DD>
</DL>
<HR>

<A NAME="getSecretDate()"><!-- --></A><H3>
getSecretDate</H3>
<PRE>
public java.lang.String <B>getSecretDate</B>()</PRE>
<DL>
<DD>返回保密期限
<P>
<DD><DL>

<DT><B>返回:</B><DD>保密期限  0     无 1    一年 2   二十年 3   三十年 </pre> <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setSecretLevel(2);  attr.setSecretDate("50年");  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode);       System.out.println("秘密等级: "+attr.getSecretDate()); </pre></DL>
</DD>
</DL>
<HR>

<A NAME="getSecretLevel()"><!-- --></A><H3>
getSecretLevel</H3>
<PRE>
public int <B>getSecretLevel</B>()</PRE>
<DL>
<DD>返回秘密等级
<P>
<DD><DL>

<DT><B>返回:</B><DD>秘密等级 <pre> 0     无 1    秘密 2    机密 3    绝密 </pre> <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setSecretLevel(2);  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode);  System.out.println("秘密等级: "+attr.getSecretLevel()); </pre></DL>
</DD>
</DL>
<HR>

<A NAME="getTelegraphLevel()"><!-- --></A><H3>
getTelegraphLevel</H3>
<PRE>
public int <B>getTelegraphLevel</B>()</PRE>
<DL>
<DD>返回紧急程度 电报
<P>
<DD><DL>

<DT><B>返回:</B><DD>紧急程度 <pre> 0     无 1    平急 2    加急 3    特急 4    特提 </pre> </pre> <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setTelegraphLevel(2);  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode);  System.out.println("电报 紧急程度: "+attr.getTelegraphLevel()); </pre></DL>
</DD>
</DL>
<HR>

<A NAME="getTitle()"><!-- --></A><H3>
getTitle</H3>
<PRE>
public java.lang.String <B>getTitle</B>()</PRE>
<DL>
<DD>返回文件标题
<P>
<DD><DL>

<DT><B>返回:</B><DD>文件标题  <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setTitle("test");  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode);  System.out.println("文件标题: "+attr.getTitle());  </pre></DL>
</DD>
</DL>
<HR>

<A NAME="setBarcodeDate(java.lang.String)"><!-- --></A><H3>
setBarcodeDate</H3>
<PRE>
public void <B>setBarcodeDate</B>(java.lang.String&nbsp;date)</PRE>
<DL>
<DD>设置条码制作日期
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>date</CODE> - 条码制作日期 <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setTelegraphLevel(2);  attr.setBarcodeDate("20051216");  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当条码制作日期date不符合日期格式
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当条码制作日期date字符串为空</DL>
</DD>
</DL>
<HR>

<A NAME="setBarcodeDeveloper(java.lang.String)"><!-- --></A><H3>
setBarcodeDeveloper</H3>
<PRE>
public void <B>setBarcodeDeveloper</B>(java.lang.String&nbsp;developer)</PRE>
<DL>
<DD>设置条码制作单位
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>developer</CODE> - 条码制作单位 <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setTelegraphLevel(2);  attr.setBarcodeDeveloper("test");  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当条码制作单位developer为空或者长度为0
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当条码制作单位developer长度大于20</DL>
</DD>
</DL>
<HR>

<A NAME="setBarcodeNumber(java.lang.String)"><!-- --></A><H3>
setBarcodeNumber</H3>
<PRE>
public void <B>setBarcodeNumber</B>(java.lang.String&nbsp;number)</PRE>
<DL>
<DD>设置条形码编号
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>number</CODE> - 条形码编号 <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setTitle("test");  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当条形码编号number为空或者长度等于0.
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当条形码编号number长度大于20或者小于8.</DL>
</DD>
</DL>
<HR>

<A NAME="setCustomFields(java.lang.String)"><!-- --></A><H3>
setCustomFields</H3>
<PRE>
public void <B>setCustomFields</B>(java.lang.String&nbsp;fields)</PRE>
<DL>
<DD>设置自定义字段
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>fields</CODE> - 自定义字段 <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setTelegraphLevel(2);  attr.setCustomFields("test");  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当自定义字段fields为null.
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当自定义字段fields长度大于110.</DL>
</DD>
</DL>
<HR>

<A NAME="setDate(java.lang.String)"><!-- --></A><H3>
setDate</H3>
<PRE>
public void <B>setDate</B>(java.lang.String&nbsp;date)</PRE>
<DL>
<DD>设置成文日期
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>date</CODE> - 成文日期 <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setTelegraphLevel(2);  attr.setDate("20051201");  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当成文日期date不符合日期格式
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当成文日期date为空</DL>
</DD>
</DL>
<HR>

<A NAME="setDepartment(java.lang.String)"><!-- --></A><H3>
setDepartment</H3>
<PRE>
public void <B>setDepartment</B>(java.lang.String&nbsp;department)</PRE>
<DL>
<DD>设置主送单位
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>department</CODE> - 主送单位 <p> <b>例子:</b> <pre>  Documents docs = Application.getWorkbooks().getActiveWorkbook().getDocuments();  Document doc = docs.getActiveDocument();  Barcode barcode = new Barcode();  barcode.setPDF417(false);  BarcodeInfo attr = barcode.getBarcodeInfo();  attr.setBarcodeNumber("12345678");  attr.setDepartment("test");  barcode.setBarcodeInfo(attr);  barcode.setForeground(java.awt.Color.RED);  barcode.setBackground(java.awt.Color.BLUE);  doc.insertBarcode(barcode); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当主送单位department为null
<DD><CODE><A HREF="../../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当主送单位department长度大于40</DL>
</DD>
</DL>
<HR>

<A NAME="setDispatchUnit(java.lang.String)"><!-- --></A><H3>
setDispatchUnit</H3>
<PRE>

⌨️ 快捷键说明

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