I readed on the post Token for URL to delete a record on how to use URLFOR, but it doesn't work in my case:

Error: Field $Action.CaseContactRole.Delete does not exist. Check Spelling.

I know based on https://help.salesforce.com/apex/HTViewHelpDoc?id=dev_action_values.htm the Delete action is not available for CaseContactRole but it's also not documented for OpportunityTeamMember.

Do you have any idea or I will have to create a an action on a custom controller to get it working?




Yes, per your link the only objects which are supported by the Delete action are custom, and

Ad group Asset Campaign Campaign member Case Contact Contract Event Google campaign Keyword Lead Opportunity Opportunity product Product Search phrase SFGA version Solution Task Text ad

So you will have to create an action on a custom controller to get it to work as expected.

An alternative is to simply output a link to:

/setup/own/deleteredirect.jsp?delID={recordId}&retURL={wherever you want}

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.