You need to sign in to do that
Don't have an account?
Heather Bazel
Error: Unknown property for standardController
Hi all,
I am learning Visualforce and I am trying to add some VF code to a Custom Object, but I keep getting this error when I try to save:
Error: Unknown property 'Revenue_Recognition__cStandardController.revenue_recognition'
Controller:
public class revRecExtension
{
ApexPages.StandardController stdCtrl;
public revRecExtension(ApexPages.StandardController std)
{
stdCtrl=std;
}
public PageReference save()
{
stdCtrl.save();
return null;
}
}
VF Code:
<apex:page standardController="Revenue_Recognition__c" extensions="revRecExtension">
<apex:sectionHeader title="Revenue Recognition"/>
<apex:form >
<apex:pageBlock title="Edit" mode="edit">
<apex:pageBlockButtons >
<apex:commandButton value="Save" action="{!save}"/>
<apex:commandButton value="Cancel" action="{!cancel}"/>
</apex:pageBlockButtons>
<apex:pageBlockSection title="Revenue Recognition Details" columns="2">
<apex:inputField value="{!revenue_recognition.duration__c}"/>
</apex:pageBlockSection>
</apex:pageBlock>
</apex:form>
</apex:page>
Any help would be highly appreciated!!
Thanks!!
Heather
I am learning Visualforce and I am trying to add some VF code to a Custom Object, but I keep getting this error when I try to save:
Error: Unknown property 'Revenue_Recognition__cStandardController.revenue_recognition'
Controller:
public class revRecExtension
{
ApexPages.StandardController stdCtrl;
public revRecExtension(ApexPages.StandardController std)
{
stdCtrl=std;
}
public PageReference save()
{
stdCtrl.save();
return null;
}
}
VF Code:
<apex:page standardController="Revenue_Recognition__c" extensions="revRecExtension">
<apex:sectionHeader title="Revenue Recognition"/>
<apex:form >
<apex:pageBlock title="Edit" mode="edit">
<apex:pageBlockButtons >
<apex:commandButton value="Save" action="{!save}"/>
<apex:commandButton value="Cancel" action="{!cancel}"/>
</apex:pageBlockButtons>
<apex:pageBlockSection title="Revenue Recognition Details" columns="2">
<apex:inputField value="{!revenue_recognition.duration__c}"/>
</apex:pageBlockSection>
</apex:pageBlock>
</apex:form>
</apex:page>
Any help would be highly appreciated!!
Thanks!!
Heather
All Answers