You need to sign in to do that
Don't have an account?
wattss
Replacing Standard Page with Custom Page
I am attempting to replace a standard page for a custom page when the New button is clicked for a custom object.
So far I have been able to create Visualforce custom page.
Next I go to Create > Objects and select my custom object.
In the Standard Buttons and Links block I click on Edit for New.
The override page is displayed however when I select Override With Visulaforce Page the dropdown only lists "-- None --"
When I click on Edit for the Tab, the override With Visualforce Page drop down lists my custom Visualforce page.
Is there a configuration/customization value I am missing?
Why is my custom page not listed in the dropdown when I attempt to override the New page?
As an example I am using the following article
http://wiki.developerforce.com/index.php/Visualforce_DynamicEditPage
I'm not if this stands with custom objects but when overriding a button on a standard object the visualforce page must use that standard controller. You controller has to act as an extension so to include the extended functionality.
So for example I override the New button on the lead object. So my VisualForce page is declared like this:
<apex:page StandardController="Lead" extensions="searchUI" tabStyle="Lead">
Not because I am actually using anything from the Lead standard controller but just so I can override the lead button. Then i included my custom controller as the extension.
All Answers
I'm not if this stands with custom objects but when overriding a button on a standard object the visualforce page must use that standard controller. You controller has to act as an extension so to include the extended functionality.
So for example I override the New button on the lead object. So my VisualForce page is declared like this:
<apex:page StandardController="Lead" extensions="searchUI" tabStyle="Lead">
Not because I am actually using anything from the Lead standard controller but just so I can override the lead button. Then i included my custom controller as the extension.
Thank you for your quick reply.
This is what I added to the Visualforce page.
<apex:page StandardController="CustomObject__c">
rather than
<apex:page>
The custom page now appears in the drop down list.