+ Start a Discussion
ehrenfossehrenfoss 

multi-picklist styling in VisualForce tabPanel

I have a tabPanel, each tab includes a VisualForce page.  I'm switching tabs via Javascript, bypassing the default SF tab navigation.  For all tabs other than the activeTab defined in the tabPanel, however, the Multi-Picklist fields are formatted badly.  They are very narrow and are rendred with "width:35px" which as far as I know cannot be overridden.

I saw in other posts in the discussion board that dynamically changing the activeTab in the tab panel (via a response from the controller, for example) is a known issue.  Is there any way to cause the Multi-picklists to all be styled as if they are on the active tab? 
Best Answer chosen by Admin (Salesforce Developers) 
ehrenfossehrenfoss
Heh, apparently noone else cares about this one, but I did find a solution.  Put this in your CSS and include it from the VisualForce page:

Code:
select {
  width: auto !important;
}


What a headache that was....

All Answers

ehrenfossehrenfoss
I ended up replacing these with multi-checkboxes (selectCheckboxes in VisualForce) per a client request...but still no idea where the width:35px comes from and how to turn it off. 
ehrenfossehrenfoss
Heh, apparently noone else cares about this one, but I did find a solution.  Put this in your CSS and include it from the VisualForce page:

Code:
select {
  width: auto !important;
}


What a headache that was....
This was selected as the best answer
Tom AsselmanTom Asselman
ehrenfoss you made my day!
Thanks for the tip !
Sales4sSales4s

 

If possible, can you post/share the JavaScript code for switching tabs? Your help will be much appreciated.

 

Regards,

Hari