What’s the best way to store values in my onboarding script?

0
2
Asked By TechieTurtle42 On

I'm working on a script to streamline the onboarding process, and I've made good progress. However, I keep hitting this error that says, 'A Value for the attribute was not in the acceptable range of values.' I think it's related to the address section of a new Active Directory user. I'm pretty sure it's the street address causing the issue, but I'm unsure about the specific problem. The script pulls data from an Excel sheet and displays it correctly, so any tips on how to troubleshoot this would be greatly appreciated!

3 Answers

Answered By ScriptNinja11 On

Could you share a snippet of your code? It might help to pinpoint the issue. You could be using the wrong attribute name for the address.

Answered By DebugDynamo22 On

It would help if you could show a simplified version of your code. This could reveal if you’re missing something or using incorrect syntax for the new-aduser or set-aduser commands.

Answered By CodeCrusader99 On

The error often means that the format of the data you’re trying to input isn’t acceptable for AD. Double-check the length of the string you're using; it might be too long. Also, confirm it's the street address field—some users have encountered similar problems with the Country field, which only accepts two-letter codes (like ‘GB’ instead of ‘UK’).

RookieBuilder88 -

That was it! The country field was the culprit, and once I removed that line from my code, everything else filled out perfectly. Thanks a ton!

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.