The use of online editors is showing a growing trend nowadays, driven by a multitude of factors, including the rise of remote working, the increasing popularity of cloud services, and the convenience that online editors offer in terms of accessibility and collaboration.
Among the rich features offered by online document editors, the security feature is highly valued by some users. Having the ability to password-protect documents online helps prevent unauthorized access, reduces the risk of data leakage, and ensures that only designated members can view or edit documents. This feature is especially important in collaborative environments where you need to control who can make changes.
In this article, we will explore two ways to protect a Word document online in the Spire.Cloud.Office document editor.
Spire.Cloud.Office Document Editor
Spire.Cloud.Office is a powerful online document editing tool designed to provide a seamless experience for editing Microsoft Office documents such as Word, Excel, and PowerPoint in web browsers. The online editing tool supports real-time collaboration, allowing multiple users to work on the same document simultaneously, which is especially useful for teams working on projects together, enabling immediate feedback and updates.
More than just a document editor, Spire.Cloud.Office can also serve as a document viewer and converter, making it a versatile tool for various document management needs. To utilize the services offered by Spire.Cloud.Office, you will need to first install it on your system.
- Install Spire.Cloud.Office for .NET on Windows
- Install Spire.Cloud.Office for Linux on Ubuntu
- Install Spire.Cloud.Office for Linux on CentOS
After the installation is complete, you can integrate Spire.Cloud.Office editor in your own web application or visit the example application hosted on port 3000 to explore the editor's functionalities.
Password Protect a Word Document Online
To encrypt a Word document with password in the Spire.Cloud.Office editor, simply follow the steps below:
1. Upload a Word document by clicking the "Upload File" button on the example page.
2. Select a file, wait a second for the editor to get the file ready, and then click "Edit".
3. After opening the file in the editor, go to "File > Document Protection > Add password".
4. Enter password in the dialogue box that pops up and click "OK" to confirm.
5. The editor will automatically save the encrypted file. Later on, anyone who wants to access the file will need to enter a password.
To change or remove password, open the encrypted document and then go to "File > Document Protection > Change password / Delete password".
Set Editing Restrictions on a Word Document Online
If you want to secure your document against accidental or malicious modifications, you can set editing restrictions on the document. In this way, users are only allowed to edit specified parts of the document, while other parts can only be viewed.
The following are the steps to restrict editing a Word document online using Spire.Cloud.Office editor:
1. When a file is opened in the editor, click the "Restricted Edit" under the "Review" tab.
2. After clicking, a "Restrict Editing" pane will appear on the right side of the document. You can select one from the drop-down menu to allow only this type of editing in the document.
3. If you want to allow certain people to edit a specific part of your document even if it’s been restricted.
First select the part that you want to keep editable, and click the "Add User" under the "Exception (optional)" section. Then enter the usernames (or email addresses) you want to allow to edit your document.
4. Tick-mark the users you just added and click the "Start Protection" button. Then enter password on the pop-up dialogue box and click "OK" to start enforcing protection on your document.
5. The editable parts will be highlighted. To remove editing restrictions on a Word document, click the "Stop Protection" button and enter the password.