zoukankan      html  css  js  c++  java
  • Aspose.Words.dll根据模板生成word详解

    1、获取word文档内容,把书签替换为文字

          Document doc = new Document("模板路径");//载入模板

          Aspose.Words.DocumentBuilder builder = new Aspose.Words.DocumentBuilder(doc);

          builder.MoveToBookmark("zy");//跳转到书签名是zy的位置

          builder.Write("书签位置要替换的文字");

         把书签替换为图片:

         builder.InsertImage(img, RelativeHorizontalPosition.Page, left, RelativeVerticalPosition.TopMargin, 0, width, height, WrapType.None);

    2、动态生成表格

    参考:https://www.cnblogs.com/abc101/p/5264280.html

    Aspose.Cells中文版文档:https://blog.csdn.net/hao_ds/article/details/38977917  导入导出Excel

  • 相关阅读:
    密码学与安全技术
    分布式系统核心问题
    虚拟机性能监控与故障处理工具
    垃圾收集器与内存分配策略
    Channel
    Buffer
    Reactor
    I/O简介
    HashMap
    装饰者模式
  • 原文地址:https://www.cnblogs.com/skyfeng-826/p/9473274.html
Copyright © 2011-2022 走看看