This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
setVerticalTextPosition and setHorizontalTextPosition act upon the text of a JLabel in relation to its image. This JLabel appears to have no image, so this won't have any effect.
Look at setHorizontalAlignment(). This will center the text in the area taken up by the JLabel. That doesn't mean the JLabel is in the center of the form. Thats up to the layout manager and the other components on the container. Welcome to the wonderful world of layout managers.
This probably belongs in the Swing Forum.
Edited - cause I can't spell [ October 11, 2006: Message edited by: Tim LeMaster ]