asked on February 17, 2017 Show version history

Hello,

I'm trying to add a new LF Name User or Trustee (Active Directory User) and assign Full License via workflows 9.2.1 but im still not able to do it, I've tried using the SDK scripts but I was only able to add the named user to the repository but not to the License Manager.

Is there any built in activity or an SDK example of how to add a Named User to the License Manager?

 

Repository (This code works)

            // create the windows account
            string acctName = @"AD\User";
            TrusteeInfo trustee = new TrusteeInfo();

            // set the feature rights and set it to read only    
            trustee.FeatureRights = FeatureRights.Scan | FeatureRights.Search | FeatureRights.Print | FeatureRights.Export;
            trustee.ReadOnlyAccess = true;
            Trustee.SetInfo(acctName, trustee, session);

            // grant logon access to the windows account (Trust)    
            AccountReference ar = new AccountReference(acctName, session);
            Repository.GrantLogOnAccess(ar, session);

 

Server Management Class Throws this error :

Trustee not found. [9012]

Server server = new Server("Server");
ServerManagement sm = new ServerManagement(server);
LaserficheNamedUserDatabase nudb = LaserficheNamedUserDatabase.GetFromServerManagement(sm);
nudb.RegisterLaserficheNamedUser(@"AD\User", "Repository", NamedUserStatus.ReadWrite);

 

Thanks

0 0