I have a page on which I'm adding rows to pageblocktable but not saving them.
<apex:commandButton value="addrows" action="{!add}"/>
<apex:pageBlockTable var="a" value="{!statuslist}" >
<apex:column headerValue="Action">
<apex:commandLink value="Delete" action="{!deleteAction}">
</apex:column>
<apex:column headerValue="status" value="{!a.status_c}">
</apex:pageBlocktable>
Method to add rows
public void add()
{
controls__c cnt = new controls__c();
cnt.status = selectedvalue; (value selected by user)
statuslist.add(cnt);
}
I want to be able to hide those particular rows on which user clicks delete. I don't have the id for the record as it is not saved. Any help is much appreciated.