Same address

I want to be able to save some time for the user and have then just click on a clickable box if the home address is same as shipping address and have the shipping address fildes fill in automatically from the home address.
I created a field called same address and made it a calculation, and made it a radio button. When they click on that button I like for it to auto fill the shipping address.
How can I get that to work?

Thanks
LVL 1
noadAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

North2AlaskaCommented:
First, I don't think it will work as you think if the field is a calculation.  Just make it a number and set the default (Auto Enter data of zero).  Next set the field on your layout as a checkbox and assign it to fire a script when checked.

The script should be pretty straight forward
Set Field ( Mailing Address::Street ; Shipping Address::Street )

For each data element you want to move over....
0
North2AlaskaCommented:
I should have mentioned you will also need to make a value list.  I typically make a list called Boolean and set as the only value as 1.  You will not really display this, it really is just to allow you to have a check box.

Then in your script you add something like this

Set Field ( YOUR_CHECKBOX ;  not ( YOUR_CHECKBOX ) )

This simply says if your checkbox is 0 set it to 1. If it is one set it to zero.

Now when you check the box it will store the value and continue with the rest of the script.
0
noadAuthor Commented:
North,

I'm stuck on your first reply I made the it into t number field, I added the auto enter data of zero ( see attached )

I made it into a check box ( see attached )

Assign script ( see attached )

Created Script ( see attached )

can you illustrate how to set it up?
Screen-Shot-2012-01-06-at-11.43..png
Check-Box.png
Button-Setup.png
Script.png
0
Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

North2AlaskaCommented:
Very rough quick demo file.  Look at the following:

1) addressSame field (Number, default zero)
2) Value list boolean
3) Script
     a) The first line sets the checkbox
     b) next lines assigns the address

Give this a try and see...
Checkbox.fp7
0
noadAuthor Commented:
Ok
On way back to station from a fire.
I'll try it out as soon S possible.
Let you know
Thanks for your help.
0
noadAuthor Commented:
North,

Not sure what I'm doing wrong, but hopefully this will better help explain what I like to do .

When I click on the blue icon I like for it to give the same values from the primary fields into the secondary fields.
Screen-Shot-2012-01-06-at-3.56.3.png
0
North2AlaskaCommented:
Just have the button run the script.  Remove the first line and then fill out the rest of the fields.  The command should take the form:

Set Field [ Table Occurrence::Field; Table Occurrence::Field ]

So, your script should look something like this, if your TO is called Person:

Set Field [ Person::firstname; Person::firstname2 ]
Set Field [ Person::lastname; Person::lastname2 ]
Set Field [ Person::addressstreet; Person::addressstree2 ]
Set Field [ Person::addresscity; Person::addresscity2 ]
Set Field [ Person::addressstate; Person::addressstate2 ]

and so forth for each field value you want to move.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
noadAuthor Commented:
Cool
I'll try it
0
noadAuthor Commented:
North,

I understand what needs to be done, but I can't seem to be bale to put the second line in.... see below this is what it let' me input.

I can select the Set Field and it let's me pick the (addressstreet ) filed, but then if I try to choose the addressstreet2 it take away the addressstreet.
HOw can I choose them both like you did in your example?
1.png
2.png
0
noadAuthor Commented:
Notrh,

I got it!!!
That was fun!

Thank you so much....

Have a awesome weekend!
0
noadAuthor Commented:
North,

North knows....LOL
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
FileMaker Pro

From novice to tech pro — start learning today.