+ Start a Discussion
CTechCTech 

AddFields method

Hi,

 

I am trying to use the addFields() method of the standardcontroller, But I am unable to use it as it is give a compilation error:

ErrorError: Compile Error: Method not yet implemented at line 6 column 17

 

I got the reference from the Apex developer guide. 

 

 

 

public TestAddFieldsMethod(ApexPages.StandardController controller)
            {
                List<String> fields = new List<String>{'Name'};
                controller.addFields(fields);
            }
Is this method exists or not?
Regards,
Bhawani

 

DharmeshDharmesh

As the controller takes the standard Controller as argument are you providing controller extention in visualforce page?

 

http://sfdc-development.blogspot.com

CTechCTech

Hi Dharmesh,

 

Thanks for replying. I think it should not be dependent on the page as this one is a standard controller method and methods never depends on the page.

 

Still page code is as following:

<apex:page standardController="Account" extensions="TestAddFieldsMethod" >
    <apex:form >
        <apex:pageBlock >
            <apex:pageBlockSection title="General">
                
            </apex:pageBlockSection>
        </apex:pageBlock>
    </apex:form>
</apex:page>

sfdcfoxsfdcfox

https://sites.secure.force.com/success/ideaView?c=09a30000000D9xtAAC&id=087300000007deXAAQ

 

This is slated for Spring '11 release, is probably in Pilot now. You can't use this until the feature is generally available, at least version 21.0, but I expect more like version 22.0.

CTechCTech

Okay, I think Apex Code development guide for winter 11 having upcoming methods also.