How do I define page layout assignments for different record types via metadata XML files?
1 Answer
Going by what the Migration Tool produces, these are stored in the profile definitions. Here's an example from one of my org's profiles:
<?xml version="1.0" encoding="UTF-8"?>
<Profile xmlns="http://soap.sforce.com/2006/04/metadata">
<!-- Field permissions -->
<!-- Layout Assignments
<layoutAssignments>
<layout>Account-Institution</layout>
<recordType>Account.Institution</recordType>
</layoutAssignments>
<!-- object permssions -->
<!-- Record Type visibilities -->
<!-- Tab Visibilities -->
<!-- User license -->
</Profile>
-
-
2They're not too bad; you can either hand code the package.xml file (which I did since our org is still new and not overly complex) or use the Force.com IDE to generate the XML. Once you have that the ANT makes it super simple to retrieve and deploy. Commented Aug 23, 2012 at 16:45