You need to sign in to do that
Don't have an account?
Aman Singh Chhokar
How to Display Integer value got from SOQL Query (Apex Class) to Visualforce Page
I am new to Apex and trying to access the value from Custom Controller having SOQL query and show it on visualforce page as an Output link.
Visualforce snippet:
Any Help would be much appreciated.
Visualforce snippet:
<div class="count"><apex:outputText value="{!Records}"/></div>Apex Code Snippet:
public Integer getDisplayQueryList() { Records = 0; Records = [select count() from Case where Type like 'MDD Increase from WSC']; return Records; }Also I have read about the AggregateResult[] which might be the best way to use but not sure how to use it properly. My main aim is to search & Count for all Cases which are NOT Closed & of Type = MDD Increase from WSC and then display that count in the visual force page.
Any Help would be much appreciated.
Whenever you use only value to display we use the getter method. So use the below code for display value :
Thanks.
All Answers
Whenever you use only value to display we use the getter method. So use the below code for display value :
Thanks.