Skip to main content

Providing Write Protection to the Project

A project can be protected against accidental changes by means of simple write protection.

Note

To protect only certain objects in the project from changes, you need user and permission management.

For complete know-how protection (protecting the project from being viewed), you need to encrypt the project with a password, dongle, or certificate.

Opening the project with write protection

To make sure that you do not make any accidental changes to the project, you can open the project in read-only mode:

Requirement: A project is not open.

  1. Click File → Open Project.

    The Open Project dialog opens.

  2. Select the project.

  3. Click the _cds_icon_arrow_down.png arrow button next to the Open button and select Open read-only from the menu.

    The project opens. At the top right in the main window a line is displayed: "The project cannot not be saved…". Now you need to select one of the offered options if you want to save the project file.

For more information, see: Open Project

Providing projects with the "Released" attribute

To protect the project against future changes, set its status to "Released". This status must then be explicitly converted back when it needs to be opened for more editing.

Requirement: A project is open.

  1. Click Project → Project Information and then the Summary tab.

  2. Enable the Released option and click OK to confirm.

  3. Save the project (for example, Ctrl + S).

  4. Click File → Open Project to open the project.

    CODESYS opens the project. At the top right in the main window a line is displayed: "The project cannot not be saved…". In case you want to save the project file, you can now remove the Released status directly using the option provided,

Providing a project in the file system with the "Read-only" property

The usual file write protection is used.

  • Provide the project file in its local file system with the "read-only" property attribute.

    If you had already opened the project and you now try to save it with the same name, then a dialog prompt opens to notify you about the existing write protection. This dialog provides you with the following options:

    You can save the project under another name or another path by clicking the Save as button.

    You can deliberately save the project with the same name and path and therefore overwrite the existing version in the file system using the Overwrite button.

    You can abort the save operation using the Cancel button (for example to remove the write protection on the disk).

    When you open the project again, a line appears at the top right in the main window 'The project cannot not be saved…'. In case you want to save the project file, you need to select one of the provided options.