示例#1
0
    private void BindGrid()
    {
        MasterGroupDAL _dal          = null;
        Hashtable      _htParameters = null;

        try
        {
            _dal          = new MasterGroupDAL();
            _htParameters = new Hashtable();

            _htParameters["p_keywords"] = txtSearch.Text;

            gvwList.DataSource = _dal.GetRows(_htParameters);
            gvwList.DataBind();
        }
        catch (Exception ex)
        {
            Utility.ShowMessageBox(this, Utility.LOAD_DATA_FAIL_MESSAGE, ex, null, null);
        }
    }
示例#2
0
    public static void BindDDLUsergroup(DropDownList ddl)
    {
        MasterGroupDAL _dalgroup = null;

        Hashtable _htParameter = null;

        try
        {
            _dalgroup    = new MasterGroupDAL();
            _htParameter = new Hashtable();

            _htParameter["p_keywords"] = "";

            ddl.DataSource     = _dalgroup.GetRows(_htParameter);
            ddl.DataValueField = "USERGROUP";
            ddl.DataTextField  = "USERGROUPDESCNID";
            ddl.DataBind();
        }
        catch (Exception)
        { }
    }