2

I am trying to create a custom EDIT ALL list button on OrderItem (Order Product) with content source as Visualforce page and am getting below error. I don't want to use standard EDIT ALL button as I want to add some new custom fields to be editable and some fields to be non editable.

Error: List controllers are not supported for OrderItem

Here is my page:

<apex:page standardController="OrderItem"  recordSetVar="EditAllProducts">
    ...
</apex:page>

Any workaround for this ?

1 Answer 1

4

This is true. Not every object is supported by the StandardSetController class, which is the underlying functionality you tap into when you implement the recordSetVar attribute in your page.

You will need to implement this as a custom Apex controller using lists, SOQL and offsets.

There is a basic example of getting this to work in the Salesforce developer blogs with sample code in a github repo.

I suggest trying that out, and then coming back with any difficulties you have at that point.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .