function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Dhruv NirgudeDhruv Nirgude 

why i am getting this error ???

Attribute value in <apex:inputField> must contain only a formula expression that resolves to a single controller variable or method in Test at line 43 column 54

<apex:page standardController="contact">
 <apex:form>
    <apex:sectionHeader title="Contact" subtitle="New Contact"/>
    <p> Contacts not associated with accounts are private and cannot be viewed by other  users or included in reports.</p>
    <apex:pageblock title="Contact Edit" Tabstyle="Contact">
   <apex:pageblocksection title="Contact Information"     columns="1" Collapsible="True">
    
       <apex:inputField value="{Contact.FirstName}"/>
        <apex:inputField value="{Contact.LastName}"/>
        <apex:inputField value="{Contact.Email}"/>
        <apex:inputField value="{Contact.Birthdate}"/>
        <apex:inputField value="{Contact.Level__c}"/>

    </apex:pageblocksection>
        <apex:pageBlockButtons>
            <apex:commandButton action="{!save}" value="save"/>
            <apex.commandButton action="{!cancel}" value="Cancel"/>
        </apex:pageBlockButtons> 
                                               
    </apex:pageblock>
    </apex:form>
</apex:page>
 
SwethaSwetha (Salesforce Developers) 
HI Dhruv ,
You are missing the ! in below code lines
       <apex:inputField value="{Contact.FirstName}"/>
        <apex:inputField value="{Contact.LastName}"/>
        <apex:inputField value="{Contact.Email}"/>
        <apex:inputField value="{Contact.Birthdate}"/>
        <apex:inputField value="{Contact.Level__c}"/>

Update above to 

       <apex:inputField value="{!Contact.FirstName}"/>
        <apex:inputField value="{!Contact.LastName}"/>
        <apex:inputField value="{!Contact.Email}"/>
        <apex:inputField value="{!Contact.Birthdate}"/>
        <apex:inputField value="{!Contact.Level__c}"/>

See example from https://developer.salesforce.com/docs/atlas.en-us.pages.meta/pages/pages_compref_inputField.htm

If this information helps, please mark the answer as best. Thank you