Hi folks, thanks in anticipation for your assistance?.
I am working on a timesheet/expensesform combination in Excel 2000
The objective is as follows:
There are 2 worksheets in the book. The first is a timesheet for tracking the hours I work. This part of it I think I have covered. Depending on the start and finish times of the shift on the day in question I may be able to claim mileage for using my own car, (e.g. if I start at 04:00 in the morning there is no public transport available, so I need to use my own car and can claim a little for fuel). The second worksheet is the actual claimform for claiming the mileage. I have this covered such that all I need enter on this form, if I want to claim for a given day, is the Date and Start/Finish times on that day.
I want to automate things such that checking a box on the timesheet transfers the Date and Start/Finish times to the claim form. I cannot change the layout of the form, as this is a standard form prescribed by my employer. The completed form, (which is printed, signed by me, then submitted), should not have ?empty? lines. It is, for example, possible that I work 6 consecutive days with only the first and last of these days giving rise to a claim. The claim form should have the data entered on 2 consecutive Rows, not with 4 blank rows between them. (Other constraints, which I needn?t detail here, mean that a ?Sort? before printing isn?t an option)
The timesheet covers a 4 week period. Columns D, F and G carry the date, start time, and finish time. (Note Col E doesn?t enter into this). Further along, in Col ?M?, there is a Checkbox. (The checkbox is named according to the Row it is in, e.g. the Checkbox associated with Row 13 is named C13). I have made sufficient progress to make sure the Checkbox(es), are enabled/disabled, (and also some other VBA aspects of the project), according to the correct time parameters. What I need help with is finding the NEXT AVAILABLE ROW on the claimform so that the data can be pasted in the correct place.
The Date, Start and Finish times on the claim form are Columns A, B and D, (Note ?C? not used). Can someone please help me with VBA code for this? It?s just locating the ?Next Free Row? that I need help with.
One of the main reasons for undertaking this exercise is to learn a bit more about VBA programming, so any explanation of any solution would be most welcome!
I hope the problem is clear?
Thanks in anticipation,
(This is the first time I've posted a problem here so apologies if I've erred with any protocols!)
Regards
Simsy
I am working on a timesheet/expensesform combination in Excel 2000
The objective is as follows:
There are 2 worksheets in the book. The first is a timesheet for tracking the hours I work. This part of it I think I have covered. Depending on the start and finish times of the shift on the day in question I may be able to claim mileage for using my own car, (e.g. if I start at 04:00 in the morning there is no public transport available, so I need to use my own car and can claim a little for fuel). The second worksheet is the actual claimform for claiming the mileage. I have this covered such that all I need enter on this form, if I want to claim for a given day, is the Date and Start/Finish times on that day.
I want to automate things such that checking a box on the timesheet transfers the Date and Start/Finish times to the claim form. I cannot change the layout of the form, as this is a standard form prescribed by my employer. The completed form, (which is printed, signed by me, then submitted), should not have ?empty? lines. It is, for example, possible that I work 6 consecutive days with only the first and last of these days giving rise to a claim. The claim form should have the data entered on 2 consecutive Rows, not with 4 blank rows between them. (Other constraints, which I needn?t detail here, mean that a ?Sort? before printing isn?t an option)
The timesheet covers a 4 week period. Columns D, F and G carry the date, start time, and finish time. (Note Col E doesn?t enter into this). Further along, in Col ?M?, there is a Checkbox. (The checkbox is named according to the Row it is in, e.g. the Checkbox associated with Row 13 is named C13). I have made sufficient progress to make sure the Checkbox(es), are enabled/disabled, (and also some other VBA aspects of the project), according to the correct time parameters. What I need help with is finding the NEXT AVAILABLE ROW on the claimform so that the data can be pasted in the correct place.
The Date, Start and Finish times on the claim form are Columns A, B and D, (Note ?C? not used). Can someone please help me with VBA code for this? It?s just locating the ?Next Free Row? that I need help with.
One of the main reasons for undertaking this exercise is to learn a bit more about VBA programming, so any explanation of any solution would be most welcome!
I hope the problem is clear?
Thanks in anticipation,
(This is the first time I've posted a problem here so apologies if I've erred with any protocols!)
Regards
Simsy