In my powershell script, I have a method that fetches a username from a sharepoint list. This works fine - my problem is that field is from a lookup column. The user chooses the username from a lookup column.
That means that the usernames are returned to my script as strings, but with a 10;#
prepended to the username where the 10
is the id of the item in the lookup's source list (I think).
But I need to have a clean username, without the 10;#
prepended.
How can I get that?