Link to home
Start Free TrialLog in
Avatar of unknown45
unknown45

asked on

Address Book Lookup

I created a view that has company, city , state, zip.

On my form i created a field called company and set it as a dialog list who gets its value from the company field of my view. Whats the easiest way to make it so when a user chooses a company it will then automatically fill out city , state, and zip fields on my form.

Thanks in advanced for any help!
ASKER CERTIFIED SOLUTION
Avatar of p_partha
p_partha

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of unknown45
unknown45

ASKER

Partha,

That works if I make the city field a dialog list, but I just want it to be a normal text field. When I make the city field a text when I try to run the form it says can not find "city" in the view, and will not let me open the form.
It should work, if you make the city field a text, Can you paste the exact formula here, and also does the document in the view has a field name by city.

If yes then try making the city field "allow multiple values"

Partha
INstead of returning one field from the dialog list, have it return all fields.  You can set up display fields that pick it apart.

Or,you can just make City a computed for display field, and have its formula be what Partha gave you.
Unfortunately I still have not gotten it to work… I am working with the state field, The below code will work if I have the field as a editable dialog list, but when I make it a computed or computed for display text box and paste this code into the default value field and then launch the form it says “Field: ‘state’:Entry not found in index or view’s index not built” --- My view is indexed and sorted ascending by Company column.

Also I kind of like qwaletee's idea of bringing everything down at the same time, how would i setup a display field to pick it apart?

Code:
@DbLookup("";""; "Address Book";cCompany; "state" )
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I never did get this to work, but it was more of a experiment with something and not a major project. Will split points and close.