Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [standardcontroller]

A StandardController is a built-in controller available for standard and custom objects to facilitate the easy creation of Visualforce pages.

13
votes
2answers
4k views

Sort Order of Child Records Using a Standard Controller

Does anybody know of a way to order child records when accessed using a StandardController and displayed with an <apex:repeat> loop? My guess is that it can't be done and I need an extension, ...
2
votes
2answers
18k views

How to Write Test Class for Standard Controller Along With Extensions

Hi Everyone I'm finding it difficult to write test class for this class Class public class SendEmailReceipt{ public Payment_Receipts__c Rec; public string em{get;set;} public id ...
0
votes
2answers
1k views

Access a variable in VF page from Controller without using get set method

I have a visual force page as below: <apex:page standardController="Interview__c" extensions="SkillReviewExtension"> <apex:form > <apex:pageBlock title="Candidate Skill ...
3
votes
1answer
486 views

“Data not available” when using Database.rollback() in custom save action

In my custom edit page for LineItem__c records I have overriden the save button with my own implementation which does not only save the record itself but also change to child records. <apex:page ...
3
votes
2answers
218 views

Can I send a user to an edit page which, when they press Save, will send them to the detail page?

Related: Can I send a user to a standard layout edit page at the end of a wizard? I have implemented a wizard that sends the user to the standard edit page at the end of the wizard. It's working ...
3
votes
2answers
5k views

Iterating over related records in visualforce using standard controller

I'm diving into visualforce and the standard controller for the first time and having trouble iterating over a single opportunity's related records. The below code produces an error: <apex:page ...
13
votes
4answers
11k views

Required fields do not allow cancel

I have a custom VF page that I am using as a custom cases page, standardController="case". I have an apex:form with a few apex:inputField to create the boxes. Inside the form I have a save and cancel ...
7
votes
1answer
1k views

How do I access the standard controller without passing the ID parameter in the URL

How can I use the standard controller to access fields on a record in a visualforce page without passing the ID in the URL? Example: Instead of "https://c.xxx.visual.force.com/apex/abc?id=...
6
votes
1answer
939 views

Visualforce error using standard controller in managed package

I have an inline visualforce page which uses a standard controller. I check values from the record object in javascript so I can display some other records in a popup based on the value of customfield....
1
vote
1answer
6k views

Creating Test Class for VF Page Controller

Having trouble creating a test class for my VF Page Controller I am trying to develop. I have created an inbound change set in my Production, and an outbound in my Sandbox. Now I am at the step of ...
1
vote
1answer
1k views

StandardController of Account to show a pageblocktable of related child object from an extension errors out

I have a object Competitor_Mapping__c that has lookup with Account. In the page, i have used standard controller of Account to fetch the current Account id from URL, used in a SOQL to populate a list ...
0
votes
1answer
1k views

override standard edit button based on recordtype

I have a requirement to show different edit layout, based on recordtype, using standard edit button override. I'm trying to create a visualforce page and assign it to the edit button, refrering this ...
6
votes
1answer
846 views

Can there be a Shared Extension across Multiple Overridden Visualforce Pages?

I would like to know if its possible to share a common extension class across multiple Visualforce Pages which use different standard Controllers. For Eg., I've VF_A Page which overrides default ...
5
votes
1answer
273 views

Is there away to pull a users standard layout in edit mode and place it on a VF page?

I know there's a ways to do this using tag to view the detail page, but once you hit edit it will use salesforce standard edit page. I've also created a custom edit page but the problem I'm running ...
4
votes
1answer
3k views

Can you access parent object fields in a 'New' page override without using SOQL?

I have two objects, Parent__c and Child__c, Child__c has a lookup field to Parent__c calledParentId__c. I have overridden the New and Edit pages for Child__c using a Visualforce page with the ...
3
votes
1answer
600 views

Accessing parent by a standard controller

I have page which uses contact standard controller which is as below <apex:page standardController="contact"> {!contact.account.name} </apex:page> When I pass a valid id for contact ...
2
votes
2answers
895 views

Id none must be 15 characters

I am getting below error during execution time for below code in Apex page. I am unable to assign the value from here to standard controller. Can someone please help me? Apex Page <apex:...
1
vote
1answer
7k views

How to display a Related List in a Visualforce page

Can any one help me out ?I'm Creating an OpportunityLineItem(Opportunity Product) page in Visualforce page and now how should i call the related list(Schedule) fields to get display in Visual Force ...
1
vote
1answer
63 views

How to create contact detail page using controller? [duplicate]

How to create contact detail page using controller? <apex:page standardController="Contact" extensions="ContactDetailController"> <apex:form > <apex:pageBlock mode="maindetail" title="...
0
votes
2answers
1k views

account list as radio button options in VF page

I have the below VF page where I am trying to list the account and contact details as radio button options: <apex:page standardController="Account" recordSetVar="accounts"> <apex:form &...
0
votes
1answer
37 views

cover standardcontroller extension in test class

public DiscoverOrg_ConflictResolver(ApexPages.StandardController controller) { LoadPage(); // Research request start reportSubmited = ''; reportNotSubmited = ''; ...
0
votes
0answers
78 views

How to avoid page reload on standard Edit action?

I have two pageBlocksection and i put QuickSave action on first PageBlocksection and it's working fine and it's rerender the next pageBlocksection but Now, i want one button on Second pageBlocksection ...
0
votes
1answer
1k views

How to pass ContactId to Visualforce page, standardController is Opportunity

I have a visualforce page where I want to pass the Contact Id into the visualforce page. This is because I have a flow imbedded in the vf page, which needs a contact id to create Opportunity COntacts. ...