to singlepine(小山): 为什么我双击控件不会出现代码? 还有在override protected void OnInit(EventArgs e)里敲this.没有出现我的控件? 是不是控件没有实例化?如何实例化?
解决了! ActiveX控件不能作为服务器控件运行。 可在脚本语言里调用控件的方法,代码如下: <SCRIPT language="vbscript" id="clientEventHandlersVBS"> <!-- Sub button1_onclick ActiveX控件ID.方法(参数) End Sub --> </SCRIPT>
override protected void OnInit(EventArgs e)
{
InitializeComponent();
base.OnInit(e);
this.控件.click+=//此时就会出现它的方法和属性,选中你要的事件,按tab,再按tab,事件自然会被加入
}
为什么我双击控件不会出现代码?
还有在override protected void OnInit(EventArgs e)里敲this.没有出现我的控件?
是不是控件没有实例化?如何实例化?
ActiveX控件不能作为服务器控件运行。
可在脚本语言里调用控件的方法,代码如下:
<SCRIPT language="vbscript" id="clientEventHandlersVBS">
<!--
Sub button1_onclick
ActiveX控件ID.方法(参数)
End Sub
-->
</SCRIPT>