You need to sign in to do that
Don't have an account?

Custom controller extension
Please find below code:
public class MyController {
private final Account account;
public MyController() {
account = [SELECT Id, Name, Site FROM Account
WHERE Id = :ApexPages.currentPage().getParameters().get('id')];
}
public Account getAccount() {
return account;
}
public PageReference save() {
update account;
return null;
}
}
In above example is it possible to change the method name "save"? I am new to the visualforce. Any help would be really appreciable.
Thank you..
public class MyController {
private final Account account;
public MyController() {
account = [SELECT Id, Name, Site FROM Account
WHERE Id = :ApexPages.currentPage().getParameters().get('id')];
}
public Account getAccount() {
return account;
}
public PageReference save() {
update account;
return null;
}
}
In above example is it possible to change the method name "save"? I am new to the visualforce. Any help would be really appreciable.
Thank you..
Hi,
Hope this helps,
You cant change the name directly in VF Page.
1.First remove the name "save" from VF page and save the page.
2.Change the name in Class then VF Page.
All Answers
yes in the custom controller you can change the name of the method
i hop its helps you
Thanks
Mark it best answer if it helps you :)
yes, it is possible to change.
Thanks
Aniket
Hi,
Hope this helps,
You cant change the name directly in VF Page.
1.First remove the name "save" from VF page and save the page.
2.Change the name in Class then VF Page.