How to position the form in the center screen?

后端 未结 9 1871
小鲜肉
小鲜肉 2021-01-30 05:05

I\'m a .Net developer but somehow I was task to create a simple application in java for some extra reason. I was able to create that application but my problem is how can i cent

9条回答
  •  悲哀的现实
    2021-01-30 05:33

    Actually, you dont really have to code to make the form get to centerscreen.

    Just modify the properties of the jframe
    Follow below steps to modify:

    • right click on the form
    • change FormSize policy to - generate resize code
    • then edit the form position X -200 Y- 200

    You're done. Why take the pain of coding. :)

提交回复
热议问题