| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 1605 人关注过本帖
标题:静态方法中不能使用this,还有什么办法?
只看楼主 加入收藏
jljhwang
Rank: 1
等 级:新手上路
帖 子:21
专家分:0
注 册:2008-6-30
收藏
 问题点数:0 回复次数:1 
静态方法中不能使用this,还有什么办法?
pubic class maForm:Form
{
pubic void showfrmChild()
{
frmChild frm=new frmChild(this);
frm.Show();
}
}
pubic class frmChild:Form
{
public frmChild(maForm parent)
{
this.Mdiparent=parent;
}
}

pubic class newChild:Form
{
这里我该怎么调用maForm中的showfrmChild()方法?
}
其实就是在一个Form的子窗口中调用另一个子窗口。
搜索更多相关主题的帖子: 静态 办法 
2008-06-30 21:53
admin312
Rank: 1
等 级:新手上路
帖 子:7
专家分:0
注 册:2008-7-3
收藏
得分:0 
maForm form = new maForm();
form.showfrmChild();
2008-07-03 23:07
快速回复:静态方法中不能使用this,还有什么办法?
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.019371 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved