This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Creating a duplicate Object using vbscript with Permissions

I am trying to do the same thing here and the script example works.

Copying Objects (m-files.com)

The only issue is that the duplicate file is created with no permissions.

I inserted this line to see if it would change the permission on the new file, but all it it does is change the permissions to the old file which I don't need because it is already there.

Vault.ObjectOperations.ChangePermissionsToNamedACL ObjVer, 20, False     '20 is the NACL ID I am using.

All I want is for the script to keep the same permissions as the original object.

Please advise.

Parents
  • When you call CreateNewObjectEx you provide an access control list.  The sample creates a new/blank Access Control List but it sounds like you want to use the Access Control List of the source object instead. I haven't tried this but I assume you would call GetObjectPermissions and then get the resulting ACL from that and provide it when creating the object.

Reply
  • When you call CreateNewObjectEx you provide an access control list.  The sample creates a new/blank Access Control List but it sounds like you want to use the Access Control List of the source object instead. I haven't tried this but I assume you would call GetObjectPermissions and then get the resulting ACL from that and provide it when creating the object.

Children