Activity Forums Salesforce® Discussions Can we use Standard Controller & controller attributes at a time in Salesforce?

  • chanchal kumar

    Member
    October 5, 2018 at 1:36 pm

    Hi,

    No, We cannot reference both attributes at a time.

    See below syntax to understand

    <apex:page standardController=”ControllerName” extensions=”Class1, Class2,..”> Correct

    <apex:page Controller=”MYControllerName” extensions=”Class1, Class2,..”>   Correct syntax

    <apex:page standardController=”MYControllerName” Controller=”MyController”>  Wrong

  • Divya

    Member
    October 26, 2018 at 1:47 pm

    Hi Anjali,

    A custom and standard controller cannot be referenced in the same page. Another way is you use extensions instead of Custom Controller.

  • William

    Member
    January 30, 2019 at 4:42 am

    No a custom and standard controller cannot be referenced on the same page. A custom and standard controller should not be supported at the same time; another way is you can use extensions instead of Custom Controller.

    Ex- <apex:page standardcontroller=""  extensions="controller name"/>

     

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos