Autofill field...
Autofill field...
- Subject: Autofill field...
- From: Brad Bumgarner <email@hidden>
- Date: Mon, 17 Jul 2006 15:49:37 -0600
I'm rapidly running out of hair here and the floor around my desk
looking pretty hairy. lol
I'm trying to implement an "autofill" field the same as Mail.app does
in the "To:" token field. I want to be able to input a person's first
name --or-- last name first.
I am currently taking the string and breaking it into component parts
with a space (" ") character as the separator. I am then searching
the Address Book using each component as a possible first name and as
a possible last name. These queries are stored in sets (to eliminate
duplicates).
If there is only one string component the union the 2 sets together.
If there is more than 1 set I intersect them. This works great, BUT
with 2 problems that I haven't been able to eliminate. First is when
a space (" ") is entered, I get NO results back. Second is when one
string component is only 1 character in length. I get more "hits"
then I should.
Does anybody know how the Mail.app does it? (Because unfortunately I
don't and haven't been able to get it right.)
Thanks,
Brad Bumgarner, CTA
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden