Creating AD users trough Powershell activity in UiPath - powershell

Im trying to create AD users with Invoke Powershell activity.
Unfortunately I am stuck with a Parameter problem.
The parameter “Name” gives following error: “The Object name has bad syntax”
The funny thing is, if I run the same powershell command directly into powershell console, I get no error.
But when the robot runs it. I get parameter error.
See screenshots for clarification.
I really hope someone can crack this code, because I am pretty stuck here.
-Christian

Maybe it's too many " chars in name field? Try to change it to "Robot5" for example.
-
Egor

Related

extension properties displayed in graph but not in powershell

i have synced an extension "departmentnumber" to azure ad.
I can see the output in ms graph, when i do the following: https://graph.microsoft.com/v1.0/users/*************************?$select=extension_450c0e26a8a440748e1e4f*******_departmentNumber
The problem is, that I can not see it in powershell. There is only a blank field as you can see here:
As I understood it, there should be another row with this output: extension_450c0e26a8a440748e1e4f*******_departmentNumber
Where is my mistake?
purpose: i want to get an export, where every user is listed with the assigned licences and the departmentnumber which will get added in onprem AD. If anyone has a better solution - please tell me
Thx for yourt help guys!! :)

KsqlRestClient.makeKsqlRequest("RUN SCRIPT ...") doesn't work without filling ksql.schema.file.content with the script content yourself

In my Scala application, I am trying to tell my KSQL Server that it should execute the RUN SCRIPT <script> command, using the KsqlRestClient.makeKsqlRequest(String ksql) function. Every time I tried it, nothing happened, even though the response was successful, so I started debugging, where I saw that the response was a success but it also returned some kind of error that the property ksql.schema.file.content was empty.
Since I did not find any documentation as to what to fill this property with, I tried some things and eventually found out that if you fill this property with the contents of your .sql file, the run script command works.
Does anybody know if and with what ksql.schema.file.content should normally be filled and/or if the way I am using it is how your supposed to execute a script in KSQL from a Scala application. I already copy and pasted the text from the makeKsqlRequest into the KSQL CLI and everything worked fine, so there should be no error with that.
There is a Github issue tracking the fact that the RESTful API is not documented / supported yet, (as of March 2018).
It sounds like this is something you may want to add a +1 too.

Issue in removing user to a mailbox Exchange Server 2010 (set-mailbox remove)

I tried with many options like checking add/remove permissions users to the others mailbox users, but its not working.
I executed below command in my Exchange Management Shell :
Set-Mailbox 'mailboxname' –GrantSendOnbehalfto #{ Remove="john#ncbb.com","kim#fghgh.com" }
error: the command completed successfully but no settings of 'mailboxname' have been modified.
The error that you have listed isn't really an error, it's more of a warning. It's not telling you that it can't do something, it's just saying the parameters you provided don't exist.
I recently wrote a script that had the same issue, and I just had to mess around with it. Mine ended up needing the sAMAccountname instead of email or surname/givenname. In other words, instead of using 'test.account#abc.com', it wanted TAccount which was the username.
It may help to dig into your AD, or install an LDAP browser or AD Explorer to see what your organization names things. When I did this, I found out that half of the things I was calling in my scripts by name was completely incorrect just because of the naming convention.

MongoDB script doesn't seem to execute properly but no error code or exit code

I am a beginner and will try to explain my question as thoroughly as possible, but thank you in advance for your patience.
I am trying to run a script in MongoDB. The script is using Google Geocoding to update Twitter records. When I run the script, I get a message saying (in short) the code will exit when I have reached my daily limit of 2500 records.
My question is: how do I know when the code has exited and, also, if the script executed successfully?
Nothing seems to be happening but I am not getting an error of any kind. Additionally, when I check the log file, it appears to be blank. I have tried to search this several different ways but I'm not sure I'm using the proper lexicon as I am new to this. Any help would be greatly appreciated.

Change workstation OU without AD tools in Powershell

Right now I have a pushbutton tool, which is basically a fancy GUI that calls the DSMOVE command.
Is it possible to change a workstation account to another OU (in powershell natively) without actually having the AD tools for powershell installed? I do have the syntax to be able to see what OU I am in, but I can't find a way to change it. I'd like to cut out the DSMOVE executable.
The next question would be, how do I?
Without any tools (or error checking, or anything similar):
$User = [adsi]'LDAP://CN=BielawB,CN=Users,DC=monad,DC=ps1'
$User.MoveTo('LDAP://OU=Destination,DC=monad,DC=ps1')
Obviously, it would be wise to wrap it in some function and add some checking/ error handling.
I've used user object, but that's not different for any other AD object...