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
shan876shan876 

System.ListException: Missing id at index: 0 for delete testing????

Does anyone know what does this define:
System.ListException: Missing id at index: 0

I am trying to delete in my testmethod the item i created during my testmethod and it does not work...
anyone have an example of using delete in there test methods or what
that message defines.
Thanks
BoxBox

if you put the code section up that you're having problems with we will be more that willing to point you in the right direction.

lrw757lrw757

For anyone else who may be having problems with this, make sure the record you are trying to delete has actually been instaciated - i.e. item = new item__c();