I need to trim text from a cell. I am not sure how to create the function in Excel

I have this cell value of:

CN=John Doe,CN=Users,DC=mydomain,DC=int

Every cell is like this as I am getting it from Active Directory.  What I need is a function to give me just the name.  So the next cell's value is John Doe.  I think the function is trim, but not sure how to grab just the users name from this cell value.  Only thing I see common is the name starts after the "=" and there is a comma right after the name.  Your help is greatly appreciated.
get-ADuser -F ($_.Name -eq "Todd")I.T. ManagerAsked:
Who is Participating?
Glenn RayConnect With a Mentor Excel VBA DeveloperCommented:
If the cell value shown is in cell A1, then this formula will extract the name only:

get-ADuser -F ($_.Name -eq "Todd")I.T. ManagerAuthor Commented:
That is Brilliant Glenn Ray.  Works great.  I am going to ask another question here shortly.  If you can figure out, I am putting Active Directory info in an access database for some other I.T. people to look at.  If all possible,  I would like to get the first and last name in two separate cells.  I will reference you and your solution in case it helps.  Thank you so much
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.