I need to update incremental code in a custom field on accounts. So that, If user changes the Type from Prospect to customer then no. should be incremented by 1.
For account1, it will be C1
For account2, it will be C2
For account3, it will be C3
Whenever user changes the type from Prospect to Customer, It will pick the last no. of previous record and then it will increment. Code will be unique for each account as we need to use the same code for integration purpose.
Just create a Text field like i created "customautono__c" in account object.
Go to devloper console
create new trigger on before update event for Account.
So whenever your account Type gets updates "customautono__c" field will get a new value.