Advertisement
Guest User

Untitled

a guest
Jun 25th, 2019
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.58 KB | None | 0 0
  1. <apex:page controller="SampleCode">
  2. <apex:form>
  3. <apex:repeat value="{!AccountList}" var="a">
  4. <apex:outputField value="{! a.Name}"/>
  5. </apex:repeat>
  6. <apex:commandButton value="Submit" action="{! submit}"/>
  7. </apex:form>
  8.  
  9. public class SampleCode {
  10. public List<Account> Accounts=new List<Account>();
  11. public List<Account> getAccountList(){
  12.  
  13. Accounts=[Select Id,Name from Account];
  14. Details();
  15. Return Accounts;
  16. }
  17. public pageReference submit(){
  18. system.debug(2);
  19. //code here
  20. return null;
  21. }
  22.  
  23. public void Details(){
  24. //Details code here
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement