Created
April 2, 2018 02:46
-
-
Save forcethesales/28672a309639c6dbbf73ebec98d847cc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
trigger AccountAddressTrigger on Account (before insert, before update) { | |
// Get the List of accounts | |
//List<Account> newAccts = new List<Account>( | |
//[SELECT Id,Match_Billing_Address__c,BillingPostalCode,ShippingPostalCode FROM Account WHERE Id IN :newAccts]); | |
for(Account alice : Trigger.New) { | |
if (alice.Match_Billing_Address__c == true) { | |
alice.ShippingPostalCode = alice.BillingPostalCode; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment