Questions tagged [controller-extension]

A controller extension is an Apex class that extends the functionality of a standard or custom controller.

Filter by
Sorted by
Tagged with
0
votes
1answer
26 views

Error: Method does not exist or incorrect signature: void getRecord() from the type VFAccount

I am trying to create a custom controller and extension to create account records. But I am stuck with this error I am facing. I have tried many other tips to make this work and but no avail. This is ...
0
votes
1answer
35 views

VF Page is not updating the record

I have a VF page to update couple of fields on the Opportunity record, it is a simple VF Page like below <apex:page standardController="Opportunity" extensions="Opportunity_UpdExt&...
1
vote
1answer
617 views

How can i open a pop up box with event information when event url is clicked in the Full calendar?

I used jquery full calendar and this pageload() on document.ready with list of events in calendar. Here is my Controller: <apex:page controller="NetworkCalendar" standardStylesheets="false" ...
1
vote
1answer
33 views

No Save and Controller Extensions throw Unknown Property Errors

For clarity, and as I accepted an answer in the last question, I am posting a new question for additional help with new issues. The last question can be reviewed here. Here are my new issues: When ...
2
votes
2answers
2k views

How can I use pagination in a VF page when using a Controller Extension?

I have a Visualforce page with the following attributes <apex:page standardController="Asset" extensions="myAssetsExtension" sidebar="false" showHeader="false" standardStylesheets="false"> I ...
0
votes
2answers
62 views

Unknown Property Error on VF Main Extension

UPDATE 12/29/2020: For clarity, and as I accepted an answer here, I am posting a new question for additional help with new issues. The new question can be reviewed here. UPDATE: I am trying to switch ...
2
votes
2answers
4k views

field validation on approve or reject for approval process

I am creating an Approval Process. Its a simple process with 2 approval steps I have a requirement where an assigned approver (user) must populate one or more fields on a record before they approve or ...
0
votes
0answers
36 views

Standard List Controller extension not working

I am preparing for the PD1 exam and I was practicing an example on the standard list controllers using extension. The extension class limits the opportunity to show only 2 records but it is showing ...
0
votes
2answers
66 views

“System.NullPointerException: Attempt to de-reference a null object” when deploying controller + test class

I am trying to learn development while building Apex classes. I got this error upon trying to deploy a custom controller and test class from sandbox to production: "System.NullPointerException: ...
0
votes
1answer
29 views

Controller Extensions no Longer Working

Update I seem to also not be able to render a section based on the value of a user-input field in my form when the logic is called directly within my VF page. Code from VF page User-filled form field ...
1
vote
2answers
32 views

Visualforce - PageBlockTable blank or invisible rows

I have a fairly simple code where I'm querying an object, getting the records and mapping them to a list in order to show them in a VF page. The page is still unfinished but I'm wondering what is ...
0
votes
0answers
23 views

Apexpages.addmessage() is showing but the design is not coming with it. Please help

I am adding the images for the code and output. Please look into it and help. Thanks
0
votes
2answers
76 views

Attempt to de-reference a null object error on User-Input Form

UPDATE Update to my Apex public with sharing class ShouldShowSHSection{ public ShouldShowSHSection(ApexPages.StandardController paramController) { Intake = paramController;} public ...
0
votes
1answer
14 views

Issue with the Visualforce page with the Controller extension

I am trying to create a VF Page on the Case, where I should be able to get the Contact associated with the case. I created a Controller extension like below public with sharing class ...
0
votes
1answer
468 views

Is there a way to make a PageReference method an InvocableMethod?

This is the scenario: I had a VF page call a controller extension,that would have some criteria and redirect the user to a different page (or not, depending on the criteria). Now, everything starts ...
0
votes
2answers
1k views

How to pass multiple selected values from apex:selectList to controller?

I haven't been able to find an answer to this as all the answers are somewhat different to what I'm trying to achieve. Summary before giving the details: apex:selectList where the values are ...
0
votes
1answer
30 views

How to add delete button on each record in pageBlock table - VF

I have an extension that allows users to input information and I am trying to add delete functionality to each record in apex:pageBlockTable. How can I edit my extension code to add this? What I've ...
0
votes
3answers
2k views

How to display records on a pageblocktable based on the value of a picklist field?

Hi i am new to salesforce. I want to display some records on a pageblocktable, which must be based on the picklist field. e.g. If i select Quarter4 from quarter picklist field pageblocktable must show ...
0
votes
2answers
37 views

Controller Test to Cover Delete

I have what I think is a simple controller and test class, but when I try to compile the test class, I get an error related to my deleteAddress() method: System.QueryException: List has no rows for ...
0
votes
1answer
27 views

Getting error as “ Error: Unknown property 'AccountStandardController.conList' in VisualForce page”

Visual force page code: <apex:page standardController="Account" extensions="Contactextctroller" recordSetVar="lstacc" setup="false" sidebar="false"...
0
votes
0answers
9 views

Help with Controller Extension Test Class, [duplicate]

I have a very simple controller extension and I'm trying to write a test Class, but I am only able to get 12% coverage. I'm not sure how to cover the rest of thelines below. Right now only my ...
0
votes
2answers
98 views

Standard fields translation

I need to translate product names and their descriptions, using workbench i can only translate cutoms fields. Is there a reliable ISV or API that i can use for translation? thanks in advance
1
vote
3answers
53 views

Embed Visualforce Related List on Account

I have a custom object call Account_Addresses__c that has a master-detail relationship to the Account record. I am trying to create a Visualforce page that will be embedded in the Account Detail to ...
0
votes
2answers
52 views

How to fetch parent object field from child object's on vf page extension

We have two objects SieBid_Opportunity__c which is child object and SieBid_Account__c which is parent. I have created a vf page with standard controller of SieBid_Opportunity__c which shows the lookup ...
0
votes
1answer
134 views

HELP displaying related contacts of all accounts in hierarchy?

I want to show in child accounts, the related contacts of the parents and other child accounts too. I almost solved this with a Visualforce Page and a Controller, but the related contacts are shown ...
1
vote
1answer
388 views

Visualforce page usingbase standard controller

I have the following Visualforce page and controller: <apex:page standardController="sObject" extensions="ExtensionController"> <div> {!o.Id} </div> <div>...
0
votes
1answer
81 views

Upsert failed.INVALID_ID_FIELD, record id cannot be empty key: []

I'm a beginner developer and I'm building a custom NEW contract button. I'm having issues getting the contract to insert/upsert and I think it has something to do with having a standardsetcontroller ...
0
votes
1answer
29 views

Attempt to de-reference a null object error after selecting Visualforce page dropdown value

I'm a beginner developer and I'm building a custom new contract button with a visualforce page with dropdown field values that unhide other fields depending on what is selected. Clicking the button ...
0
votes
3answers
445 views

Save form - Lightning component

I'm trying to save custom object's records using lightning component , the form contain lookup fields ( multi select records ) , i have developed a LC to be able to select multi records on custom ...
0
votes
1answer
100 views

Save button (associated to standard controller method) not working on visualforce page (standard controller + extension)

I'm creating a VF page with a list of all contacts on the top and a form to insert a new one on the bottom but the last feature doesn't work. This is the code of the VF page: <apex:page ...
0
votes
2answers
22 views

How to get language from visualforce into into controller extension

I am using a force.com site to show a visualforce page where I want the user to have the option to select a language. In the corresponding visualforce page I set the language. How do I get this into ...
0
votes
1answer
34 views

Unable to get the edited values to Controller without using wrapper

I tried searching for a solution before posting it here but no luck. I have a VFP with account fields and custom InputText field which is used to capture "Other" value which is concatenated(some ...
0
votes
0answers
17 views

Insert URL parameter into Apex controller extension save function

I am trying insert a parameter into the record that already exists and then put in the save method in an apex controller extension for a standard controller. This is the controller extension pretty ...
1
vote
1answer
83 views

Error when I try to create OrderItem records Insert failed. INVALID_CROSS_REFERENCE_KEY

I'm trying to create a visualforce page where a user can create multiple OrderItem records at the same time. The error that I get is OrderItem records Insert failed. First exception on row 0; ...
0
votes
1answer
91 views

How to compare a duplicate list values and delete it

I have a use case where in 1 Order Contains multiple OrderItems, and these orderitems contains records. lets say there are 5 orderitems to 1 order, and among 5 orderitems 2 are duplicate and 3 are ...
4
votes
3answers
10k views

Build a String for Database.query

for an exstention controller of a VF page, I need to build a query to retrieve all the lead with a Company name similar to a variable. My variable name is compagnia: Now I'm trying to build the query ...
0
votes
1answer
25 views

Controller Extension - Report Data Tables

What is the correct way to declare and reference a report data table (in Visualforce)? The report is filtered by account, and I want it to be visible when rendered as "pdf". I'm writing a ...
1
vote
1answer
57 views

Custom component setter value being passed in to controller, but getter always returns null (or the initialized value)

The setup: I have a standard controller with two extensions on it. <apex:page standardController="Contact" showQuickActionVfHeader="false" extensions="ExtOne,ExtTwo"> <c:...
0
votes
1answer
32 views

Test Class For FinishURL StandartsetController

I have an APEX class that ends with a finishURL method; this class is the controller-extension of a VF page. What they all do is to collect the IDs of the selected items on a related list view, then ...
0
votes
1answer
633 views

How to get ID from aggregateresult[] groupedresult

I have an aggreateresult[] soql as follows: AggregateResult[] groupedResults = [SELECT id, Account__c, Account__r.Account_ID__c, MAX(Account_c__C) FROM ...
0
votes
1answer
1k views

How to pass list view selected items from one visualforce page to another

So I have a custom object called Transactions, and have recently made a list view button that will redirect the user to a visualforce page that will show the selected record, and provide a few buttons ...
0
votes
1answer
229 views

Display the Variable vale in the VF Page from Extension Class

Req is as below: I need to display the variable from the extension class of the Standard controller: Variable name is : String unreleasedCheck{get;set;} String unreleasedCertificat{get;set;} VF ...
0
votes
1answer
29 views

How to fix Custom URL controller - public page - Authorization problem

I've got a controller extension I'm trying to deploy to a public custom url. It works in our sandbox, and I can access it with "Preview" under the custom url, but I get the dreaded Authorization ...
2
votes
1answer
500 views

How to auto populate the lookup field value into the text field in visualforce page?

I am trying to auto populate the value of lookup field to text field in the visualforce page. As soon as I select the value of lookup field from the list the value as it get populated in the lookup ...
0
votes
0answers
119 views

SFDC Flow Launched from Custom Button

I have a custom button on the Opportunity object that launches a Visualforce page. The Visualforce page passes the Opportunity ID to the Flow then launches it and sets the finish location. I know my ...
0
votes
1answer
288 views

issue with userdata in test class for auto registration handler class

I have a test class which is as below @isTest private class KC_Reg_Handler_Test { static testMethod void testCreateAndUpdateUser() { KC_RegHandler handler = new KC_RegHandler (); ...
13
votes
3answers
8k views

'Map key null not found in map' when using apex:pageBlockTable

I have a simple controller extension with has a method which returns a Map<String, Map<String, Boolean>. public class UserExtension { private final User theUser; public ...
1
vote
1answer
77 views

how to make test class for controller with parameter canvas.toDataURL()

I made extension class and VF page for getting signature image. I confirmed it works well through many test . And then, I need to make test class to deploy that extension class into production org. ...
1
vote
1answer
388 views

Updating Custom Object using Visualforce

I am trying to update fields on a custom object using visualforce. I have embedded a visualforce page on Lead Layout that displays records of my custom object linked to the lead. I want to update ...
0
votes
1answer
32 views

Issues with insert/creating a record in custom object using custom controller

VF Page <apex:page standardController="Applications__c" lightningStylesheets="true"> <apex:sectionHeader title="Application For Employment"/> <apex:form > <apex:pageBlock >...

1
2 3 4 5
9