You need to sign in to do that
Don't have an account?
veeru417
need help:implementing functionality like Copy Billing Address to Shipping Address in accounts
Is it possible to implement a functionality like Copy Billing Address to Shipping Address link (which is avilable in account object Address Information pageblock ) in my custom object
Yes possible..
1. Use Apex class to write a controller to get the address wherever you want.
2. Write a VF Page using the controller to call the function in the class
3. Create a button to call this VF page
All Answers
Yes possible..
1. Use Apex class to write a controller to get the address wherever you want.
2. Write a VF Page using the controller to call the function in the class
3. Create a button to call this VF page
I would use a trigger, like such:
hi,
I am new to this technology,i am learning on my own.can you suggest any doc or site to learn apex class in better way.
i want to implement functionality like whenever i click the link then only it will copy the field value into specified field.Is it possible?Help me in developing that.
Thanks,
veerendranath
Not sure what you mean by "whenever i click the link"
If you're new, there is a lot of documentation on developer.force.com, in example: http://wiki.developerforce.com/page/Forcedotcomworkbook
Have a look at the forc.com, apex, visual force and database workbooks, they helped me out a lot.
Can anyone give in detail with code so that whenever i click on button shipping address to copy into billing address
i have wriiten trigger like this . Can you check and give me some output . i want two issues to solve in this code
1. Can we reduce the code in a smarter way as iam new i written like this.
1. it is only working when we save record for first time. i mean if we edit that and again save it is not reflecting.
Can you please solve as it is very urgent for me.
trigger AccountTrigger on Account (before insert, before update) {
List<Account> lst_in = trigger.new;
for(Account acc:lst_in){
if(acc.ShippingCity != null && acc.BillingCity == null ){
acc.BillingCity = acc.ShippingCity;
}
if(acc.ShippingStreet != null && acc.BillingStreet == null){
acc.BillingStreet = acc.ShippingStreet;
}
if(acc.ShippingState != null && acc.BillingState == null){
acc.BillingState = acc.ShippingState;
}
if(acc.ShippingPostalcode != null && acc.BillingPostalcode == null){
acc.BillingPostalcode = acc.ShippingPostalcode;
}
if(acc.ShippingCountry != null && acc.BillingCountry == null){
acc.BillingCountry = acc.ShippingCountry;
}
}
}