DMDSystemLoadData DLD01 = new DMDSystemLoadData();
Thread Thread01 = new Thread(new ParameterizedThreadStart(ThreadReadDataFormDataBase));
MSS.ThreadBase.Parametric.parametricBase PB01 = new MSS.ThreadBase.Parametric.parametricBase();
PB01.HashTableObjec.Add("Control", PB01_Login); //用与值的回调
PB01.HashTableObjec.Add("UserName", UserName);
PB01.HashTableObjec.Add("PassWord", PassWord);
PB01.HashTableObjec.Add("Type", ThreadBase.RemotingType.UserService);
DLD01.PReadDataFormDataBase += new DLoadData(DLD01_PReadDataFormDataBase);
Thread01.IsBackground = true;
Thread01.Start(PB01);
以后是委托的函数
void DLD01_PReadDataFormDataBase(object O1, MSS.ThreadBase.Parametric.parametricBase PB01)
{
发生错误就在这。为什么PB01为null,如果不使用smartassembly加密则PB01有值,如果加密后就为null ,是混淆出错,还是smartassembly不支持的问题。
if (PB01 == null)
{
PB01_Login.Visible = false;
Base.MsgBox.Show("登录失败!请输入用户名后重试!");
return;
}