So i have several dropdown menues, where VersionBox, ClassBox etc already is predefined by my code.
So what i am having trouble with, is to have a dynamic way to change the range values. it all depends on the version, the class, scaling, max weight and so on.
TypeBox: Increases the range with 1x(Normal), 5x(Post Scale) and 20x(scale)
WeightBox: sets max weight of the range
VersionBox: What version i want to work with
ClassBox: Which Sub Version i want to work with
UnitBox: it i want it to be in g, Kg or lb
So depending on what i choose from these boxes, i want the table to change. Any who knows a good way to do this?
So what i am having trouble with, is to have a dynamic way to change the range values. it all depends on the version, the class, scaling, max weight and so on.
TypeBox: Increases the range with 1x(Normal), 5x(Post Scale) and 20x(scale)
WeightBox: sets max weight of the range
VersionBox: What version i want to work with
ClassBox: Which Sub Version i want to work with
UnitBox: it i want it to be in g, Kg or lb
So depending on what i choose from these boxes, i want the table to change. Any who knows a good way to do this?
Code:
Sub VersionBox_Click()
If VersionBox = "OIML R51 1996 (Old EU)" And ClassBox = "Y(a)" And TypeBox = "Normal" And ScaleIntervalBox = "Single" And WeightBox = "1000" Then
Range("A14").Value = "5 & < m < 500"
Range("A15").Value = "500 & < m < 2000"
Range("A16").Value = "2000 & < m < 1000"
Range("A17").Value = ""
Range("M14").Value = "e = 1"
Range("M15").Value = "e = 1"
Range("M16").Value = "e = 1"
ElseIf VersionBox = "OIML R51 2006 (New EU)" And ClassBox = "Y(a)" And ScaleIntervalBox = "Single" Then
Range("A14").Value = Value1 & " < m < 500"
ElseIf VersionBox = "OIML R51 2006 (New EU)" And ClassBox = "Y(b)" And ScaleIntervalBox = "Single" Then
Range("A14").Value = Value1 & " < m < 50"
ElseIf VersionBox = "OIML R51 2006 (New EU)" And ClassBox = "Y(a)" And ScaleIntervalBox = "Multi" And ScaleIntervalBox2 = "10/20" And ScaleBox = "Normal" And WeightBox = 1000 Then
Range("M14").Value = "e = 10"
Range("M15").Value = "e = 10"
Range("M16").Value = "e = 20"
Range("M17").Value = "e = 20"
ElseIf VersionBox = "OIML R51 2006 (New EU)" And ClassBox = "Y(a)" And ScaleIntervalBox = "Multi" And ScaleIntervalBox2 = "20/50 V1" Then
Range("A14").Value = "100 < m < 10000"
ElseIf VersionBox = "OIML R51 2006 (New EU)" And ClassBox = "Y(a)" And ScaleIntervalBox = "Multi" And ScaleIntervalBox2 = "20/50 V2" Then
Range("A14").Value = "100 < m < 1000"
End If
End Sub