Post

3 followers Follow
0
Avatar

Convert user name to text string

I'm trying to create a custom field that converts a user name (reference to user object) to a text string.

For example, I am trying to covert Project Manager to text. I have tried "ToString($ProjectManager)" This returns the email address of the user. Any ideas?

 

Thank you!

Leo Lovely Answered

Please sign in to leave a comment.

5 comments

0
Avatar

In some companies they username is the email address - is the scenario in your case different? Verify that indeed the usernames are not email addresses.

If they're not, I'll have to then dig around and try and help...

Guy 0 votes
Comment actions Permalink
0
Avatar

Well, it turns out that the user name is, in fact, the email address, which explains my predicament. I guess, I really want to reference the "Name" which I can't figure out how to do?

Thanks for your help.

Leo Lovely 0 votes
Comment actions Permalink
0
Avatar

Check the formula builder, it should be something like: ToString($ProjectManager.Name)

Guy 0 votes
Comment actions Permalink
0
Avatar

Formula editor on User element does not permit "ToString($ProjectManager.Name)" it returns error: Error: The field '$ProjectManager.Name' is invalid. You can only select fields from the current object.

Leo Lovely 0 votes
Comment actions Permalink
0
Avatar

From the user object you should be able to just use $Name, but I'm not sure what your exact use case is.

Josh Santos 0 votes
Comment actions Permalink