This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal



Feb 27, 2012, 3:58 PM
26 Posts

Centering controls?

  • Category: Other
  • Platform: Windows
  • Release: 8.5.3
  • Role: Developer
  • Tags:
  • Replies: 2
Why can't I center a any control?   They have the center style:
 
style="font-weight:bold;font-family:Trebuchet MS,sans-serif;font-size:11pt;text-align:center"
 
But it does not center then the control  the browser.
 
 
 
 
 
Feb 27, 2012, 4:57 PM
366 Posts
Re: Centering controls?
 Place the controls in a div or panel and then set the center style property on that control.
 
All controls in that "container" will now be centered on the "page" 
 
Paul T. Calhoun 
Feb 27, 2012, 5:57 PM
1 Posts
Re: Centering controls?
Unfortunately this will only apply if the contained elements are 'display: inline'.
 
The way you're supposed to centre block level elements in CSS is to use "margin:auto". This will make sure that the margins on each side of the element will be equal, meaning that it will be centred in its containing element.
 

This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal