Пример #1
0
        private void 查詢資料()
        {
            string l_str所別 = "";

            if (!"".Equals(iv_cbo所別.SelectedValue))
            {
                l_str所別 = iv_cbo所別.SelectedValue.Substring(0, 3);
            }

            string l_str業代員編  = iv_txt業代員編.Text.Trim().ToUpper();
            string l_str匯入方式  = iv_cbo匯入方式.SelectedValue;
            string l_str入帳銀行  = iv_cbo入帳銀行.SelectedValue;
            string l_str匯入日期起 = iv_txt匯入日期起.Text.Trim();
            string l_str匯入日期止 = iv_txt匯入日期止.Text.Trim();

            CKGPointDetailFactory l_factory = iv_context.CFactoryManager.CKGPointDetailFactory;

            CKGPointDetail[] l_codes = l_factory.getCKGPointDetailBy條件(l_str所別, l_str業代員編, l_str匯入方式, l_str入帳銀行, l_str匯入日期起, l_str匯入日期止);

            if (l_codes != null)
            {
                display(l_codes);
            }
            else
            {
                GridView1.DataSource = null;
                GridView1.DataBind();
                ScriptManager.RegisterClientScriptBlock(UpdatePanel1, typeof(UpdatePanel), "OK", "alert('查無資料');", true);
            }
            //Session.Add(SealedGlobalPage.SESSIONKEY_KGPOINTDETIAL_REPORTEXCEL, l_codes);
        }