(ORG-8018) Project Protection with Admin Password
We have introduced the concept of Admin Mode to the Origin Project, with an Admin password. Once a project is protected by a password, worksheet and workbook protection features can be accessed only after user has logined with the admin password. We have also added LabTalk access to protect books and sheets.
App Title Bar Indication of Admin Mode
Normally, Origin title bar looks like this
there is a "-" that separates the 32/64 bit and the path of the file. To save space, we are just changing this "-" character to indicate Admin status.
For OPJ file that has added Admin password, the "-" character will be replaced by the "@" character before you enter the Admin password to login, like this
After login, the "@" character is replaced by the "=" character, like this
Admin Mode LabTalk Commands
The following is a listing of the currently supported doc commands control the Admin mode. Text inside square brackets indicate.
Command | Description | Examples |
---|---|---|
| Add Admin password password to the project. You will still need to login after adding password to turn on Admin mode. When you do not specify a password, then "origin" is assumed. Not using password will help situation where security is not so much of a concern and not running the risk of forgetting the password used. |
|
doc -pw [password] | login with password, if no Admin password added yet, error message will be shown | doc -pw; doc -pw test; |
doc -pwx | logout, once logout, cannot change anything related to protections | |
doc -pwta | list all the book/sheets with protection turned on | |
doc -pwr [password] | remove password, if no password specified, then must login first to do so, otherwise must give correct password | doc -pwr; |
After a command is entered, you App title will change accordingly, so will the status bar to indicate current status.
Protection Flags
Various objects like worksheet, workbooks can be assigned different protection flags. These flags are listed in the following table
Hex Value | Description |
---|---|
2 | Data: This include all the cells in a worksheet, data cells or label cells |
4 | Style: Display style, like the color of the cell, or the cell formatting, this is currently not yet fully implemented |
10 | Formula: Column Formula, Analysis Operation, Codes attached to Project etc. |
80 | Structure: This include like the number of rows and columns in a worksheet. inserting, deleting etc. |
Workbook Worksheet Protection Commands
Multiple protection flags can be combined
Command | Description | Examples |
---|---|---|
| set worksheet write access flags |
|
layer -lt | print out current protection flags | |
page -lw n | set workbook write access flags | |
page -lt | print out the current protection flags | page -lw; //lock book and all sheets, nothing can be change and cannot delete book or sheets |