Form1里有一个SearchKey():
public string SearchKey()
{
this.Activate();
txtCusno.Text = ClassModule.sSearchKey;
txtCusno.Focus();
return ClassModule.sSearchKey;
}
Form2用反射来调用Form1的SearchKey(),SearchKey()代码能执行,但是Form2始终在Form1的上面,并且Form1的txtCusno控件并没有被赋值和获得焦点.请问如何解决.谢谢.
public string SearchKey()
{
this.Activate();
txtCusno.Text = ClassModule.sSearchKey;
txtCusno.Focus();
return ClassModule.sSearchKey;
}
Form2用反射来调用Form1的SearchKey(),SearchKey()代码能执行,但是Form2始终在Form1的上面,并且Form1的txtCusno控件并没有被赋值和获得焦点.请问如何解决.谢谢.
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货