You need to sign in to do that
Don't have an account?
Campaign object doesn't appear to allow 'create' via force Sites
Hi everyone,
I have created a visualForce page that has a couple "<apex:inputField>" for the 'campaign' object. When I view the VF page directly in Salesforce, it appears correct with the input box. But when I view it via 'Sites', the input area/box is not displaying as though the fields are 'read only'. I assumed it was an issue with 'field security' and the guest user profile but the fields are set to 'editable'. I also verified that 'view' and 'create' were checked for the 'Standard Object Permissions' for the profile. I tested it with other objects and only campaigns seems to be an issue?
Here is the sites page:
http://icbeta1-developer-edition.na2.force.com/
http://icbeta1-developer-edition.na2.force.com/
Fields:
<apex:inputField id="inputValue" value="{!campaign.startDate}"/>
<apex:inputField id="inputValue2" value="{!campaign.isactive}"/>
Thanks ahead of time!
<apex:page standardcontroller="Campaign">
<apex:form >
<apex:pageBlock title="School Recruiter Events">
<apex:pageBlockButtons >
<apex:commandButton action="{!save}" value="Save"/>
</apex:pageBlockButtons>
<apex:pageBlockSection title="Event Details" columns="2">
<apex:inputField id="inputValue" value="{!campaign.startDate}"/>
<apex:inputField id="inputValue2" value="{!campaign.isactive}"/>
</apex:pageBlockSection>
</apex:pageBlock>
</apex:form>
</apex:page>
All Answers
have you tried with mode="edit"?
<apex:pageBlock title="School Recruiter Events" mode="edit">
Thanks for the suggestion Bulent but this didn't resolve the issue. Here is the updated code:
</apex:page>
Could this be a system error? I've also replicated it on other Salesforce instances, provided access to all objects (where applicable), and tested with other objects to verify they didn't have the same issue. It seems to me that it could be an issue/conflict with the fact that you cannot select 'marketing user' for the 'sites' profile user. (which offcourse is required to create campaign records for standard SF users).