예제 #1
0
        public void AddAndGetLoginDetails(DO_Login objLogin, Login_1 flag)
        {
            SqlConnection conn = new SqlConnection();
            SQLManager    co   = new SQLManager();

            conn = co.GetConnection();
            //conn.Open();
            cmd             = new SqlCommand("scrl_LoginUserSP", conn);
            cmd.CommandType = CommandType.StoredProcedure;
            cmd.Parameters.Add("@FlagNo", SqlDbType.Int).Value            = flag;
            cmd.Parameters.Add("@RegistrationId", SqlDbType.BigInt).Value = objLogin.intRegistartionID;
            cmd.ExecuteNonQuery();
            co.CloseConnection(conn);
        }
예제 #2
0
        public DataTable GetDataTable(DO_Login objLogin, Login_1 flag)
        {
            DataTable dt = new DataTable();

            SqlConnection conn = new SqlConnection();
            SQLManager    co   = new SQLManager();

            conn = co.GetConnection();
            SqlDataAdapter da = new SqlDataAdapter("scrl_LoginUserSP", conn);

            da.SelectCommand.CommandType = CommandType.StoredProcedure;
            da.SelectCommand.Parameters.Add("@FlagNo", SqlDbType.Int).Value         = flag;
            da.SelectCommand.Parameters.Add("@RegistrationId", SqlDbType.Int).Value = objLogin.intRegistartionID;

            da.Fill(dt);
            co.CloseConnection(conn);
            return(dt);
        }