Ray Spackman
Registered User.
- Local time
- Today, 13:45
- Joined
- Feb 28, 2008
- Messages
- 52
First, I apologize if this has already been specifically covered, however, the further I search for the answer or example, the more confused I seem to get.
Second, I hope my explanation of the situation and requested goal is clear.
I have a form; frmbowlerspecs that contains a few user input fields; numTilt, txtRotationDescrip, txtSpeedDescrip, and txtRevsDescrip.
This form also has 2 fields; numInitialDARatio, and numInitialVARatio that will show the values I am trying to return form a separate table.
The table; tblDualAngleRatios is indexed with a primary key field; AxisTilt, and has 9 other columns; HRevsandLRotDA, HRevsandLRotVA, HRevsorLRotDA, HRevsorLRotVA, SRMatchedDA, SRMatchedVA,HSpeedorHRotDA, HSpeedorHRotVA, HSpeedandHRotDA, and HSpeedandHRotDA.
Attached is a picture of my table for clarification:
In VBA I am trying to find and return the appropriate value that corresponds to the correct axistilt, which matches the forms numTilt value, and the corresponding column which is designated by the comparison of two of the three other user input fields on the form ie: txtRotationDescrip and txtSpeedDescrip.
A part of the code to help clarify my goal:
Private Sub RatioCalc()
Select Case numTilt
Case 2.5
Select Case True
Case txtRotationDescrip = "High" And txtSpeedDescrip = "High"
numInitialDARatio = ??????? THE CODE TO GET THIS VALUE
numInitialVARatio = ??????? THE CODE TO GET THIS VALUE
End Select
End Select
End Sub
In this example tblDualAngleRatios.AxisTilt would match 2.5 while the comparison of txtRotationDescrip = "High" and txtSpeedDescrip = "High"
would correspond to tblDualAngleRatios.HSpeedandHRotDA or tblDualAngleRatios.HSpeedandHRotVA while numInitialDARatio would = the value in tblDualAngleRatios.HSpeedandHRotDA and numInitialVARatio would = the value in tblDualAngleRatios.HSpeedDescripandHRotVA, both in the in the tblDualAngleRatios.AxisTilt, which in this case is 2.5.
Was trying to accomplish this with some form of lookup but not having any luck and do not know the correct or best way to accomplish this or have I seen an example of such.
Thank you in advance.
Second, I hope my explanation of the situation and requested goal is clear.
I have a form; frmbowlerspecs that contains a few user input fields; numTilt, txtRotationDescrip, txtSpeedDescrip, and txtRevsDescrip.
This form also has 2 fields; numInitialDARatio, and numInitialVARatio that will show the values I am trying to return form a separate table.
The table; tblDualAngleRatios is indexed with a primary key field; AxisTilt, and has 9 other columns; HRevsandLRotDA, HRevsandLRotVA, HRevsorLRotDA, HRevsorLRotVA, SRMatchedDA, SRMatchedVA,HSpeedorHRotDA, HSpeedorHRotVA, HSpeedandHRotDA, and HSpeedandHRotDA.
Attached is a picture of my table for clarification:
In VBA I am trying to find and return the appropriate value that corresponds to the correct axistilt, which matches the forms numTilt value, and the corresponding column which is designated by the comparison of two of the three other user input fields on the form ie: txtRotationDescrip and txtSpeedDescrip.
A part of the code to help clarify my goal:
Private Sub RatioCalc()
Select Case numTilt
Case 2.5
Select Case True
Case txtRotationDescrip = "High" And txtSpeedDescrip = "High"
numInitialDARatio = ??????? THE CODE TO GET THIS VALUE
numInitialVARatio = ??????? THE CODE TO GET THIS VALUE
End Select
End Select
End Sub
In this example tblDualAngleRatios.AxisTilt would match 2.5 while the comparison of txtRotationDescrip = "High" and txtSpeedDescrip = "High"
would correspond to tblDualAngleRatios.HSpeedandHRotDA or tblDualAngleRatios.HSpeedandHRotVA while numInitialDARatio would = the value in tblDualAngleRatios.HSpeedandHRotDA and numInitialVARatio would = the value in tblDualAngleRatios.HSpeedDescripandHRotVA, both in the in the tblDualAngleRatios.AxisTilt, which in this case is 2.5.
Was trying to accomplish this with some form of lookup but not having any luck and do not know the correct or best way to accomplish this or have I seen an example of such.
Thank you in advance.