function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Matrix ReturnsMatrix Returns 

update selected record ids using Apex controller from List View

Shivdeep KumarShivdeep Kumar
Hi Rajdeep,

If you select multiple records through checkbox then you can not do the same. but using multiple chckbox and inline editing is possible, means inline editing of all records you have selected .
If you want to do the same then there are two solutions either you can use inlineEdit tag or you can use rendered attribute.
If you want the salesforce standard funtionality that in each record there is a edit button then you can do the same with the help of actionFunction and apex:Param.

Please let me know which solutions do you want.

Thanks
Shivdeep
Matrix ReturnsMatrix Returns
User-added image
i want to save changes like this using a controller
Matrix ReturnsMatrix Returns
public class UController{
    
    ApexPages.StandardSetController setCon;
    public Account account{get;set;}
    public List<Account> acclist;
    public UController(ApexPages.StandardSetController controller)
    {
        setCon = controller;
         
    }

   public pageReference save()
    {
        // do something with the selected records
        for ( Account acc : (Account[])setCon.getSelected() )
        {
             //   System.debug('Account name = ' + acc.Name);
               acclist=[Select Name,Type,BillingState from Account Where Name =:acc.Name ];
               update acclist;
        }
        return null;
    }
   /* public List<Account> getAccountData() {
    account=[Select Name,Type,BillingState from Account];
    acclist.add(account);
    return acclist;
    }
    
    public pageReference save(){
    getAccountData();
    update account;
    
    return null;
    
    }*/
}
Shivdeep KumarShivdeep Kumar
Hi Rajdeep,

Please take a look on below link, it will help you,

https://www.linkedin.com/pulse/how-do-inline-edit-custom-visualforce-page-ravi-kant
http://salesforceworld.blogspot.in/2011/06/inline-editing-in-visualforce-page.html
http://sfdcsrini.blogspot.com/2014/08/inline-editing-in-visualforce-page.html

Please let me know if this help, else post the vf page also I ll correct that.

Thanks
Shivdeep
Matrix ReturnsMatrix Returns
Its selecting all the account but i needUser-added image when i click mass edit it wil select those particular accounts