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
Roger PavelleRoger Pavelle 

how do I put two panels on an apex form

Hi,

I have an apex form that has two parts to it:  the first part is a list of search criteria and the second part is a table with search results.

Is there a way to have these two parts display side-by-side on the form?

Thanks.
Best Answer chosen by Roger Pavelle
Roger PavelleRoger Pavelle
I decided to try going with a combination of PanelGrid and PanelGroup tags.  That seems to do 80% of what I am looking for, and the other 20% may be possible as well (I have separate questions out on the discussion board about those).

Thanks.

All Answers

Jason HardyJason Hardy
The easiest way to accomplish it would probably be to use a component. You'll need to make sure that you set the allowDML to true on your form though. Salesforce disables it by default. Example:
<apex:page>
....
  <apex:pageBlock>
    <c:searchComponet param1="xyz"..../>
    <c:resultComponent paramR ="abc".../>
  </apex:pageBlock>
</apex:page>
Here is a good article: https://developer.salesforce.com/page/Controller_Component_Communication
Roger PavelleRoger Pavelle
I decided to try going with a combination of PanelGrid and PanelGroup tags.  That seems to do 80% of what I am looking for, and the other 20% may be possible as well (I have separate questions out on the discussion board about those).

Thanks.
This was selected as the best answer