I'm using MavensMate with Sublime Text 3 to deploy some information to a sandbox, but having difficulty finding metadata relating to the List Views of standard and custom objects. These List Views are not on custom Visualforce pages. Is it possible to manipulate this information using MavensMate or do I need to do this config in the sandbox?


You can edit list views by opening the objects/ folder, finding the .object file that you want to modify, and finding the section of listViews elements, which describe each of your list views. You'll want to read all about it in the documentation.

<?xml version="1.0" encoding="UTF-8"?>
<CustomObject xmlns="http://soap.sforce.com/2006/04/metadata">
. . .
        <label>All Mileages</label>
        <booleanFilter>1 AND 2</booleanFilter>
            <value>Eric Bristow</value>
        <label>My Mileages</label>
. . .

You can retrieve them my specifying the ListView or CustomObject metadata type in your package.xml; the latter will also include fields, record types, and so on, while using the ListView type directly gives you just list views.

MavensMate, Eclipse, Developer Workbench, Force.com CLI, and any other tool capable of deploying .object files can update the list views using the appropriate .object file.

  • This is exactly what I was looking for. For Custom Objects, if only the default view exists (usually called "All"), none of the metadata for that default view is pulled in. – evankincade May 6 '16 at 20:47
  • @evankincade Yeah, you can only pull in editable list views, which is kind of annoying sometimes. – sfdcfox May 6 '16 at 21:00
  • Definitely. Do you know if this is a Salesforce-enforced barrier or functionality that MavensMate hasn't taken into account? – evankincade May 6 '16 at 21:30
  • @evankincade it's a limitation of the metadata API. Almost all current tools use the input and output from the metadata API verbatim. – sfdcfox May 6 '16 at 21:32

You should be able to edit your package.xml to pull down the ListView Metadata.

Check out this link from Salesforce on editing the package.xml to snag ListView metadata.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.