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
Hardik ChavdaHardik Chavda 

Subscript is invalid because list is empty.

str = new list<String>();      
setOfCustomerIssue = new set<String>();
                
if(Que.Customer_Issues__c != null){
CustomerIssue = Que.Customer_Issues__c;
                    
for(String s : CustomerIssue.split(';')){
Str.add(s);
setOfCustomerIssue.add(s);
}
}
Below is my class code.
 
<li>
<apex:variable var="i" value="{!0}"/>
<apex:repeat value="{!AssWrapperList[CurrentPos].str}" var="item">  
<span style="color: #667B8D;font-weight: 700;">{!item}</span><br/>
<apex:variable var="i" value="{!i+1}"/>
</apex:repeat>
</li>
Below is page code. And I'm facing error like "error is in expression
{!AssWrapperList[CurrentPos].str}
". Can anyone help me with this?
 
KaranrajKaranraj
Is there any variable in your visualforce page with the variable name CurrentPos? I think you need change the 'CurrentPos' into 'i' in your visualforce page.
{!AssWrapperList[i].str}