+ Start a Discussion
Scott0987Scott0987 

Show input field in a panelbaritem.

I want to make a set of searches on a visualforce page that list the search boxes when the user clicks on the panelbar for the item they want to search for.  So I would have 3 or 4 panelbaritems and when the user clicked on the one they wanted they would be shown the search boxes for the fields that they can search.  Here is what I have written:

<apex:panelBar >

<apex:panelBarItem label="Lead Search">
<apex:form >
<apex:inputField value="{!lead.name}" label="Name" rendered="true" />
</apex:form>
</apex:panelBarItem>
</apex:panelBar>

 

the panelbar displays correctly, but it will not show the inputfield on it.  Thanks for your help.

Best Answer chosen by Admin (Salesforce Developers) 
Scott0987Scott0987

I figured out what I was doing wrong.  You have to use inputtext not inputfield

All Answers

ar_sfdcar_sfdc

you will have to use the 'rerender' attribute for that to happen. so wherever the change happens and you want field to show, on that action event, say rerender='the parent component id' 

 

Let me know if that helps.

 

Regards,


Arun

Scott0987Scott0987

I don't think there is a rerender attribute for either the input field or the panelbaritem field.  I am also not sure exactly how I would use it.  I want the field to show up the minute the panelbar is opened.  Can you explain how to use it?  Thanks for the help. 

Scott0987Scott0987

I figured out what I was doing wrong.  You have to use inputtext not inputfield

This was selected as the best answer