1

When I click the hourglass to lookup a related record I see a list of "recently used" records.

However it's quite likely that a user will want to see all the records. I need to see all Users that match a certain Profile.

I've enabled Advanced Lookup in search settings, but this only seems to give me the choice between searching only the name, vs searching all fields. I actually want to search a specific field.

Eg search Profile="Senior Officer".

Can this be done?

1

Listing out all the potential lookup values isn't currently possible, although it would be reelly nice. Users consistently expect this behavior and get confused why the record they're looking for isn't in the list. It doesn't help that the wildcard search can be a little difficult to get used to.

As you may already be aware you can change which fields show up in the lookup dialog by editing the "Lookup Dialog" search layout for the object, but as noted on that page this doesn't affect which fields are searched by the global search, beyond the name / all fields checkboxes.

Also, as you may be aware you can alter which fields are available for filter results, but again, those aren't available for searching, just for filtering the results from the search.

Finally, the closest you can get to all is using a two letter search with wildcards on both sides, e.g. Bo, but as far as I know that's the best you can do.

1

One way to do what you are looking for is to create your own custom lookup using javascript, visualforce and apex. Jeff Douglas wrote an article on how to do this here, although it appears that the photo links are broken. I can verify that his solution works as I modified it to create my own custom lookup. You would want to modify his search code to filter the results based on the Profile you want to search for.

Admittedly, it's a lot to go through if you don't have experience programming on the salesforce platform so you will have to decide if the level of effort is worth it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.