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
jayasuriya janarthanjayasuriya janarthan 

Removal of List elements from another Lists?

There are two lists (UserProduct And List Product) , each of  it holding Product code and Product Name.On selecting a particular user from picklist UserProduct Lists displays Products based on picklist value and ListProduct displays all the Products in org. Including Products displayed in UserProduct Lists.How to remove the Products of UserProduct List displayed in  ListProduct Lists?
NagendraNagendra (Salesforce Developers) 
Hi Jayasuriya,

Sorry for this issue you are encountering.

You should use the List.clear() method right before refilling the list.

Here you can see the reference:  Hope this helps.

Kindly mark this as solved if the information was helpful.

Regards,
Nagendra