troubleshooting Question

Checkbox and Datatable problem in JSF

Avatar of naren1012
naren1012 asked on
Java EEJSPJava
2 Comments1 Solution2444 ViewsLast Modified:
When I am using a t:selectBooleanCheckbox inside a t:datatable the checkbox doesn't retain the selections that the user made in the first request. In the subsequent requests the selections are retained. This seems to be a very common problem when I searched google. But unfortunately I could not find any solution for solving this.
<t:dataTable border="1" value="#{bb_ValuationDashboard.snapshotRoundDTO.fmisPurSalesDtls}"
	styleClass="dataTable" width="100%">
	<t:column width="3%">
		<f:facet name="header">
			<t:outputText styleClass="styTblHeaderNew" value="Select Checkbox to select row"></t:outputText>
		<t:selectBooleanCheckbox forceId="true" id="purSles" value="#{purchasedSales.isSelected}" />
	<t:column width="14%">
		<f:facet name="header">
			<t:outputText styleClass="styTblHeaderNew" value="#{valDash.ss_displayPanel_purSalesTab_Address}"></t:outputText>
		<t:outputText value="#{purchasedSales.propertyAddress.addressLine1} 
		#{purchasedSales.propertyAddress.stateCode} " id="pAddress"></t:outputText>

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 2 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros