Trying to get my userform to behave properly.
Have two option buttons in frame but I want them to be unavailable unless Checkbox value is true.
Based on my research so far, what I have should work but alas it does not. I am still very green with VBA and could use some help.
Thats what I have so far. I honestly dont know if I am doing anything correctly. Any help is appreciated.
Have two option buttons in frame but I want them to be unavailable unless Checkbox value is true.
Based on my research so far, what I have should work but alas it does not. I am still very green with VBA and could use some help.
Code:
Public Sub Workbook_Open()
UserForm1.Show
End Sub
Private Sub UserForm_Initialize()
NSN.Value = ""
LocalAsset.Value = ""
With CarrierCombo
.AddItem "CMTT"
.AddItem "Day & Ross"
.AddItem "Delivered"
.AddItem "DHL"
.AddItem "FedEx"
.AddItem "Hand Delivery"
.AddItem "Loomis"
.AddItem "Pick-Up"
.AddItem "Purolator"
.AddItem "Pylon"
.AddItem "Speedy Messenger"
.AddItem "UPS"
End With
CarrierWaybill.Value = ""
Receiver.Value = ""
Sender.Value = ""
With ExportControl
.TextAlign = fmTextAlignCenter
.TripleState = False
End With
End Sub
Private Sub ExportControl_Click()
If ExportControl.Value = True Then
Frame1.Enabled = True
Else
If ExportControl.Value = False Then
Frame1.Enabled = False
End If
End If
End Sub
Private Sub Frame1_Change()
If Frame1.Enabled = True Then
Canada.Enabled = True
US.Enabled = True
Else
If Frame1.Enabled = False Then
Canada.Enabled = False
US.Enabled = False
End If
End If
End Sub
Thats what I have so far. I honestly dont know if I am doing anything correctly. Any help is appreciated.