/// <summary> /// ���ݲ���roleId����ȡ��ɫ��ְ����ϸ��Ϣ /// </summary> /// <param name="topicID">��ɫ��ְ��ID</param> public void LoadData(int roleId) { DataBase db = new DataBase(); //ʵ����һ��Database�� string sql = ""; sql = "Select * from [Rolemr] where RoleId = " + roleId; DataRow dr = db.GetDataRow(sql); //����Database���GetDataRow������ѯ���� //���ݲ�ѯ�õ������ݣ��Գ�Ա��ֵ if (dr != null) { this._roleId = GetSafeData.ValidateDataRow_N(dr, "RoleId"); this._roleName = GetSafeData.ValidateDataRow_S(dr, "RoleName"); this._exist = true; } else { this._exist = false; } }