当前位置:网站首页>C#/VB. Net to delete watermarks in word documents
C#/VB. Net to delete watermarks in word documents
2022-07-07 02:25:00 【51CTO】
stay Word Watermarks added to documents , Such as text watermark or image watermark , Can effectively show ownership , It can also play a certain warning effect . But what if you want to delete these watermarks ? This article will provide a way to delete Word Methods of watermarking in documents . This method is suitable for deleting text watermark and image watermark . Here are the detailed methods and steps .
Program environment
In this test , Introduce... Into the program Free Spire.Doc for .NET. Can be referenced by Spire.Doc.dll file :
Method 1: take Free Spire.Doc for .NET Download to local , decompression , install . After installation , Find the installation path BIN In folder Spire.Doc.dll. And then in Visual Studio Open in “ Solution explorer ”, Right click “ quote ”,“ Add reference ”, The local path BIN Under folder dll Add a reference to the program .
Method 2: adopt NuGet install . This can be done by 2 Methods of installation :
(1) Can be in Visual Studio Open in “ Solution explorer ”, Right click “ quote ”,“ management NuGet package ”, And then the search “Free Spire.Doc”, Click on “ install ”. Wait for the program installation to complete .
(2) Copy the following to PM Console installation .
Install-Package FreeSpire.Doc -Version 10.2.0
Specific steps :
- initialization Document An instance of a class .
- call Document.LoadFromFile(string fileName, FileFormat fileFormat) Method loading Word file .
- take Document.Watermark Property is set to null.
- adopt Document.SaveToFile(string fileName, FileFormat fileFormat) Method to save the result document to the specified path .
Complete code :
【C#】
【VB.NET】
design sketch :
边栏推荐
- 3D激光SLAM:Livox激光雷达硬件时间同步
- How can reinforcement learning be used in medical imaging? A review of Emory University's latest "reinforcement learning medical image analysis", which expounds the latest RL medical image analysis co
- Processing image files uploaded by streamlit Library
- Blackfly S USB3工业相机:缓冲区处理
- UC伯克利助理教授Jacob Steinhardt预测AI基准性能:AI在数学等领域的进展比预想要快,但鲁棒性基准性能进展较慢
- 机器人队伍学习方法,实现8.8倍的人力回报
- freeswitch拨打分机号源代码跟踪
- postgresql之整體查詢大致過程
- 人脸识别应用解析
- FLIR blackfly s industrial camera: configure multiple cameras for synchronous shooting
猜你喜欢
随机推荐
Introduction to the internal structure of the data directory of PostgreSQL
leetcode:5. 最长回文子串【dp + 抓着超时的尾巴】
ZABBIX 5.0: automatically monitor Alibaba cloud RDS through LLD
Zhang Ping'an: accelerate cloud digital innovation and jointly build an industrial smart ecosystem
[unity] upgraded version · Excel data analysis, automatically create corresponding C classes, automatically create scriptableobject generation classes, and automatically serialize asset files
postgresql 之 数据目录内部结构 简介
Processus général de requête pour PostgreSQL
机器人队伍学习方法,实现8.8倍的人力回报
长安链学习笔记-证书研究之证书模式
Zhang Ping'an: accelerate cloud digital innovation and jointly build an industrial smart ecosystem
Introduction to RC oscillator and crystal oscillator
[unity notes] screen coordinates to ugui coordinates
1个月增长900w+播放!总结B站顶流恰饭的2个新趋势
阿里云易立:云原生如何破解企业降本提效难题?
Flir Blackfly S USB3 工业相机:计数器和定时器的使用方法
Halcon实例转OpenCvSharp(C# OpenCV)实现--瓶口缺陷检测(附源码)
【论文阅读|深读】RolNE: Improving the Quality of Network Embedding with Structural Role Proximity
Tiflash source code reading (IV) design and implementation analysis of tiflash DDL module
String or binary data will be truncated
The mega version model of dall-e MINI has been released and is open for download