Hi All,
I am currently putting together a stop-gap time booking tool. I am using a userform for this.
Users will be able to add new lines, consisting of time entries for each day, against booking codes.
The number of lines needs to be dynamic. The user presses a command button to add a new row.
I have my original row, and can add a second row. However, I have "hard coded" the second row, e.g. for Monday hours entry the textbox is called monHours2.
I don't want to limit the user on the number of rows so I need something like monHours(i).
Here's what I have working so far with the hard coding:
Any and all help appreciated!
I am currently putting together a stop-gap time booking tool. I am using a userform for this.
Users will be able to add new lines, consisting of time entries for each day, against booking codes.
The number of lines needs to be dynamic. The user presses a command button to add a new row.
I have my original row, and can add a second row. However, I have "hard coded" the second row, e.g. for Monday hours entry the textbox is called monHours2.
I don't want to limit the user on the number of rows so I need something like monHours(i).
Here's what I have working so far with the hard coding:
Code:
Set bfMonHours2 = Controls.Add("Forms.textbox.1", bfMonHours2)
With bfMonHours2
.Top = 174 + 15 * i
.Left = 156
.Width = 42
End With
Any and all help appreciated!
Last edited: