Example #1
0
        private DataTable GetWizardApprovedDate()
        {
            SqlConnection  con = SyncHelper.NewWizardConnection();
            SqlCommand     com = new SqlCommand();
            SqlDataAdapter ad  = new SqlDataAdapter(com);

            System.Text.StringBuilder sql = new System.Text.StringBuilder();
            sql.AppendLine("SELECT FileID, CONVERT(nvarchar,AppLtrDate,103) AS 'AppLtrDate' ");
            //* ModifiedDate refer as MSCApprovalDate
            sql.AppendLine("FROM Wizard_EIRAppLtrDatesView");

            com.CommandText    = sql.ToString();
            com.CommandType    = CommandType.Text;
            com.Connection     = con;
            com.CommandTimeout = int.MaxValue;

            con.Open();
            try
            {
                DataTable dt = new DataTable();
                ad.Fill(dt);
                return(dt);
            }
            catch (Exception ex)
            {
                throw;
            }
            finally
            {
                con.Close();
            }
        }