I want to create a VisualFroce page having input fields in it. I want this page to enable Guest User to enter new record in Account Object( or any other Object).
I want headStart on how to write code for Save/Search/Edit/Delete Functions on a visulaForce page.
(Assume that i have created required input fields on visualFroce Page) I can do this using Flow but i want to acheive this using VisualForce Page.Even a link to similar solved question would do.PS: Salesforce is new to me.Hello Friend,You can do it without sharing class/permission set with Account read, create, edit permissiontry this without sharing class: public without sharing class AccountController {
public Account account{get; set;}
public AccountController(){
account = new Account();
}
public void save(){
upsert account;
}
}
If this answers your question then hit Like and mark it as solution!<apex:page controller="AccountController">
<apex:form>
<apex:pageBlock title="My Content" mode="edit">
<apex:pageBlockButtons>
<apex:commandButton action="{!save}" value="Save"/>
</apex:pageBlockButtons>
<apex:pageBlockSection title="My Content Section" columns="2">
<apex:inputField value="{!account.name}"/>
<apex:inputField value="{!account.site}"/>
<apex:inputField value="{!account.type}"/>
<apex:inputField value="{!account.accountNumber}"/>
</apex:pageBlockSection>
</apex:pageBlock>
</apex:form>
</apex:page>