By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,960 Members | 2,232 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,960 IT Pros & Developers. It's quick & easy.

Insert specific data based on the text box it is going into

P: 92
How do,

I have a form with a number of textboxes that hide and unhide depending on a number or Laps of a Race. Currently I have this code to make them hide and unhide:
Expand|Select|Wrap|Line Numbers
  1. Dim LapBox as String
  3. For x = 1 To 9      'For each possible lap
  4.     LapBox = ("txtLap" & x)     'Reference the specific lap's textbox
  5.         If Laps >= x Then       'If the text box is required
  6.             With Me(LapBox)     'Using the Specific Textbox
  7.                 .Visible = True 'Make it visible
  8.             End With
  9.         Else                    'If it is not required
  10.             With Me(LapBox)
  11.                 .Visible = False    'Make it invisible
  12.             End With
  13.         End If
  14. Next x                          'Go to next text box
What I want to do is, based on what the lap is and which Race Driver is selected, bring up their Stored Lap Time in the text box. I know that this is not the best way to display the time, but it is necessary to be able to edit the time is needs be.

The RaceDriverID comes from lstRaceDriver and the Lap is relative to the text bos it is going into, ie: Lap 1 time goes into the 1st text box, and the Lap Time is stored in tblLapTimes along with the RaceDriver ID, Lap number and LapID.

All help is much appreciated,

Dec 12 '08 #1
Share this Question
Share on Google+
3 Replies

Expert 2.5K+
P: 2,653
Hello, NDayave.

Does it all mean that data for different laps is stored in single table record?

Kind regards,
Dec 13 '08 #2

P: 92
Thanks for the response, but I have managed to sort this one out.

Thanks anyway,

Dec 27 '08 #3

Expert 2.5K+
P: 2,653
You are welcome .
Dec 27 '08 #4

Post your reply

Sign in to post your reply or Sign up for a free account.