Advertisement
Guest User

Untitled

a guest
Oct 1st, 2014
209
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.86 KB | None | 0 0
  1. public with sharing class MyController {
  2. public ApexPages.StandardController stdController { get; set; }
  3.  
  4. public AxonifyRedirectController(ApexPages.StandardController controller) {
  5. stdController = controller;
  6. }
  7.  
  8. public PageReference save() {
  9. Custom__c customObject = (Custom__c) stdController.getRecord();
  10. update customObject;
  11.  
  12. return null;
  13. }
  14. }
  15.  
  16. <apex:page sidebar="false" standardController="Custom__c" extensions="MyController">
  17. <apex:outputPanel id="myPanel"">
  18. <apex:form>
  19. <apex:pageBlock title="Custom Object Setup">
  20. Please enter your custom value.<p/>
  21. <apex:inputField value="{!Custom__c.Code__c}" /><p/>
  22. <apex:commandButton action="{!save}" value="Save" />
  23. </apex:pageBlock>
  24. </apex:form>
  25. </apex:outputPanel>
  26. </apex:page>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement