_type:是需要被实例化的控件。
_tree = Activator.CreateInstance(_type) as TreeView; a:
在执行上面的语句的时候就报错。
debug单步进入到_type的构造函数中,执行完毕_type的构造函数后就报错。public tvNursePatientList()
{
InitializeComponent();//执行完毕这个构造函数后就报错。
this.ShowType = enuShowType.Bed;
this.Direction = enuShowDirection.Ahead;
//if (Neusoft.FrameWork.Management.Connection.Instance != null)
this.Refresh();
}
//InitializeComponent()的内容。
partial class tvNursePatientList
{
/// <summary>
/// 必需的设计器变量。 /// </summary>
private System.ComponentModel.IContainer components = null; /// <summary>
/// 清理所有正在使用的资源。 /// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
} #region 组件设计器生成的代码 /// <summary>
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。 /// </summary>
private void InitializeComponent()
{
components = new System.ComponentModel.Container();
} #endregion
}
执行完构造函数后就报错:值不能为空 参数名:format
奇怪了,不知道是什么错误啊。
_tree = Activator.CreateInstance(_type) as TreeView; a:
在执行上面的语句的时候就报错。
debug单步进入到_type的构造函数中,执行完毕_type的构造函数后就报错。public tvNursePatientList()
{
InitializeComponent();//执行完毕这个构造函数后就报错。
this.ShowType = enuShowType.Bed;
this.Direction = enuShowDirection.Ahead;
//if (Neusoft.FrameWork.Management.Connection.Instance != null)
this.Refresh();
}
//InitializeComponent()的内容。
partial class tvNursePatientList
{
/// <summary>
/// 必需的设计器变量。 /// </summary>
private System.ComponentModel.IContainer components = null; /// <summary>
/// 清理所有正在使用的资源。 /// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
} #region 组件设计器生成的代码 /// <summary>
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。 /// </summary>
private void InitializeComponent()
{
components = new System.ComponentModel.Container();
} #endregion
}
执行完构造函数后就报错:值不能为空 参数名:format
奇怪了,不知道是什么错误啊。
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货