• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Transfer of data from database to excel userform question

Can anyone help me? I can't figure out why only my first checkbox is working properly. :( When the fields shown below are "T", then the checkboxes in my userform should be updated immediately with the checkboxes marked. However, only the first one is working and the others are remaining unchecked. I have crossposted this as I haven't gotten a response on the other forum I have posted to: https://stackoverflow.com/questions/59721077/userform-checkbox-questions


Code:
'''MEALS ALLOWED PER SPREADSHEET TO USERFORM'''
If Sheets("Travel Expense Voucher").Range("Data_Start").Offset(TargetRow, 30).Value = "T" Then
frmUserTravel.chkMorning = Checked
Else
   frmUserTravel.chkMorning = Unchecked
   frmUserTravel.chkMorning = Enabled = False
End If

If Sheets("Travel Expense Voucher").Range("Data_Start").Offset(TargetRow, 32).Value = "T" Then
frmUserTravel.chkMidday = Checked
Else
    frmUserTravel.chkMidday = Unchecked
    frmUserTravel.chkMidday = Enabled = False
End If

If Sheets("Travel Expense Voucher").Range("Data_Start").Offset(TargetRow, 34).Value = "T" Then
frmUserTravel.chkEvening = Checked
Else
    frmUserTravel.chkEvening = Unchecked
    frmUserTravel.chkMidday = Enabled = False
End If
'''END MOVEMENT OF MEALS ALLOWED TO USERFORM'''
 
Last edited:
Back
Top