Support for Address Fields When Using the setValue() Method
For addresses on both Edit and Detail pages, you can change the Country field using the setValue() method and at the same time set other fields in the address layout relevant to the new country setting.
The field names for address fields have the format:
ParentAddressName.ChildAddressName
For example, for an Account billing address Country field:
Parent Bill To Address.Bill To Country
As a code example, you might change the country from Canada to USA, then set the state as follows:
oraclecrmod.getField("Parent Bill To Address.Bill To Country").setValue("USA");
oraclecrmod.getField("Parent Bill To Address.Bill To State").setValue("NY");
oraclecrmod.getForm().commitValues(Handler);