Command buttons and links that are associated with save, quicksave, edit, or delete actions in a standard controller are only rendered if the user has the appropriate permissions. Likewise, if no particular record is associated with a page, command buttons and links associated with the edit anddelete actions are not rendered.
Using Standard Controller Actions
Action methods perform logic or navigation when a page event occurs, such as when a user clicks a button, or hovers over an area of the page. Action methods can be called from page markup by using {! } notation in the action parameter of one of the following tags:
<apex:page> calls an action when the page is loaded
The following table describes the action methods that are supported by all standard controllers. You can associate these actions with any Visualforce component that includes an action attribute.
Action Description
save
Inserts a new record or updates an existing record if it is currently in context. After this operation is finished, the save action returns the user to the original page (if known), or navigates the user to the detail page for the saved record.
quicksave
Inserts a new record or updates an existing record if it is currently in context. Unlike the save action, this page does not redirect the user to another page.
edit
Navigates the user to the edit page for the record that is currently in context. After this operation is finished, the edit action returns the user to the page where the user originally invoked the action.
delete
Deletes the record that is currently in content. After this operation is finished, the delete action either refreshes the page or sends the user to tab for the associated object.
cancel
Aborts an edit operation. After this operation is finished, the cancel action returns the user to the page where the user originally invoked the edit.
list
Returns a PageReference object of the standard list page, based on the most recently used list filter for that object. For example, if the standard controller is contact, and the last filtered list that the user viewed is New Last Week, the contacts created in the last week are displayed.
For example, the following page allows you to update an account. When you click Save, the save action is triggered on the standard controller, and the account is updated.
Remember, for this page to display account data, the ID of a valid account record must be specified as a query parameter in the URL for the page. For example:
Those are the standard methods yes and I've already seen that documentation, but I'm looking for where can find the methods of objects where in a page layout the standard and custom buttons work. I'm trying to replicate those buttons on a visualforce page
Adding Custom List Buttons using Standard List Controllers
In addition to overriding standard buttons and links, you can also create custom list buttons that link to pages that use a standard list controller. These list buttons can be used on a list page, search results, and any related list for the object and allow you to take actions on a group of selected records. To indicate the set of records that have been selected, use the {!selected} expression.
For example, to add a custom button to a related list for opportunities that allows you to edit and save the opportunity stage and close date on selected records:
Create the following Apex class:
publicclass tenPageSizeExt {
public tenPageSizeExt(ApexPages.StandardSetController controller) {
controller.setPageSize(10);
}
}
Create the following page and call it oppEditStageAndCloseDate:
Those are the basic ones that come with any standard controllers. I'm looking for the way to get other buttons for an object. The info you are giving me has already been found online easily but finding the specific way to get the other buttons like "sharing" or "include offline" for the "account"
See here:
http://www.salesforce.com/us/developer/docs/pages/Content/pages_controller_std.htm
Command buttons and links that are associated with save, quicksave, edit, or delete actions in a standard controller are only rendered if the user has the appropriate permissions. Likewise, if no particular record is associated with a page, command buttons and links associated with the edit anddelete actions are not rendered.
Using Standard Controller Actions
Action methods perform logic or navigation when a page event occurs, such as when a user clicks a button, or hovers over an area of the page. Action methods can be called from page markup by using {! } notation in the action parameter of one of the following tags:
The following table describes the action methods that are supported by all standard controllers. You can associate these actions with any Visualforce component that includes an action attribute.
Action DescriptionThose are the standard methods yes and I've already seen that documentation, but I'm looking for where can find the methods of objects where in a page layout the standard and custom buttons work. I'm trying to replicate those buttons on a visualforce page
You need to define custom method using standard controller extension and define your logic there.
In visual force page use <apex:commandButton/> and call your method.
Nash
Is there not another way? I mean if the standard page layout already have the buttons made and working, isn't there a way to just refer to them?
See this:
Adding Custom List Buttons using Standard List Controllers
In addition to overriding standard buttons and links, you can also create custom list buttons that link to pages that use a standard list controller. These list buttons can be used on a list page, search results, and any related list for the object and allow you to take actions on a group of selected records. To indicate the set of records that have been selected, use the {!selected} expression.
For just use standard metods put this on your VF page:
</apex:pageBlockButtons>
Those are the basic ones that come with any standard controllers. I'm looking for the way to get other buttons for an object. The info you are giving me has already been found online easily but finding the specific way to get the other buttons like "sharing" or "include offline" for the "account"