I am looking to populate a field in a User Form with the sum of a range of cells based on two criteria.
Criteria 1 = Range to be determined by matching all rows in a column (Column A) in Sheet 1 that contain the same value as a textbox on the user form.
Criteria 2 = SUM of the corresponding rows in a second column (Column B) in Sheet 1 to be returned to a specific TextBox in the User Form.
I am just looking for help with the coding for one record, I can readily create the full code once I have the best way to gather this information
USER FORM FIELD DETAILS
txtPayPeriod = Value to be matched with records in Sheet 1 Column A
CmdPayPeriod = Command Button to action the sub routine (For Information Only)
txtGrossPay = SUM of Records in Sheet 1 Column B where value of Column A = txtPayPeriod value.
Many thanks
Criteria 1 = Range to be determined by matching all rows in a column (Column A) in Sheet 1 that contain the same value as a textbox on the user form.
Criteria 2 = SUM of the corresponding rows in a second column (Column B) in Sheet 1 to be returned to a specific TextBox in the User Form.
I am just looking for help with the coding for one record, I can readily create the full code once I have the best way to gather this information
USER FORM FIELD DETAILS
txtPayPeriod = Value to be matched with records in Sheet 1 Column A
CmdPayPeriod = Command Button to action the sub routine (For Information Only)
txtGrossPay = SUM of Records in Sheet 1 Column B where value of Column A = txtPayPeriod value.
Many thanks