Topic: 构造函数问题 (无法显示做的界面) |
Print this page |
1.构造函数问题 (无法显示做的界面) | Copy to clipboard |
Posted by: oath911 Posted on: 2005-06-05 23:13 //anquan.java ... ... ... public class anquan{ public static void main(String args[]) { mianban mb = new mianban(); } } //mianban.java import .... .... .... public class mianban extends JFrame{ public mianban() { super(); initialize(); } private void initialize() { this.setSize(300,200); this.setContentPane(getJContentPane()); this.setTitle("JFrame"); } ................ ............} 调试没有其他语法错误,就是提示不能处理mianban mb = new mianban();难道这个不能调用构造? 而且我在eclipse里面调试无错,但是无法显示做的界面!求解 |
2.Re:构造函数问题 [Re: oath911] | Copy to clipboard |
Posted by: mesocool Posted on: 2005-06-06 00:35 setVisible(true); or show(); |
Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1 客服电话 18559299278 客服信箱 714923@qq.com 客服QQ 714923 |