You need to sign in to do that
Don't have an account?
Richard Houston GMU
How do I get the $Action.Case.Accept to function?
I have a visualforce page with a custom controller to display a custom table of cases. I want to add a link for any given case listed for a user to accept the case. Can I use the $Action.Case.Accept function to achieve this?
When I load the page I get the following error:
"The value of the "ids" parameter contains a character that is not allowed or the value exceeds the maximum allowed length. Remove the character from the parameter value or reduce the value length and resubmit. If the error still persists, report it to our Customer Support team. Provide the URL of the page you were requesting as well as any other related information."
Page:
Controller:
When I load the page I get the following error:
"The value of the "ids" parameter contains a character that is not allowed or the value exceeds the maximum allowed length. Remove the character from the parameter value or reduce the value length and resubmit. If the error still persists, report it to our Customer Support team. Provide the URL of the page you were requesting as well as any other related information."
Page:
<apex:page controller="casePollList" > <div style="width:70%;"> <div style = "width= 100%; text-align: center; font-size: 20px;"> Academic Advising Queue </div> <apex:form > <apex:pageBlock id="myBlock" > <apex:actionPoller interval="10" rerender="myBlock" /> <apex:pageBlockTable value="{!cases}" var="c" id="myTable"> <apex:column title="Link"> <apex:facet name="header">Case Number</apex:facet><apex:outputLink value="/{!c.id}" >{!c.CaseNumber}</apex:outputLink> </apex:column> <apex:column value="{!c.IOC_flag__c}"/> <apex:column value="{!c.CaseNumber}"/> <apex:column value="{!c.Subject}"/> <apex:column title="Name"><apex:facet name="header">Name</apex:facet><apex:outputText >{!IF(c.contact.name != null, c.contact.name, c.suppliedname)}</apex:outputText></apex:column> <apex:column value="{!c.Total_minutes_in_the_queue__c}"/> <apex:column value="{!c.Type}"/> <apex:column value="{!c.CreatedDate}"/> <apex:column> <apex:facet name="header">Owner</apex:facet> <apex:outputText label="Owner" escape="false">{!c.Owner.Name}</apex:outputText> <apex:outputLink value="{!URLFOR($Action.Case.Accept,c.id)}">Accept Case</apex:outputLink> </apex:column> </apex:pageBlockTable> </apex:pageBlock> </apex:form> </div> </apex:page>
Controller:
public class casePollList { public ApexPages.StandardSetController setCon { get { setCon = new ApexPages.StandardSetController(Database.getQueryLocator([SELECT id, Subject, CaseNumber, Contact.Name, Owner.Name, Total_minutes_in_the_queue__c, suppliedName, Type, CreatedDate FROM Case WHERE owner.name='Academic Advising Requests Queue' order by CreatedDate Asc])); return setCon; } set; } // Initialize setCon and return a list of records public List<Case> getCases() { return (List<Case>) setCon.getRecords(); } }
if helps mark as helpful with your solution for this code.
I've tried with the below code working fine.
<apex:outputLink value="{!'/'+c.id+'/a'}"> Accept Case</apex:outputLink>