Hi,
Need some help with either an XltoLeft or XltoRight Autofill
I have a userform where the user selects their shift start time and then their shift end time both from inbuilt combobox to ensure uniformity.
For example:
Shift Start Time 9
Shift End Time 17
On pressing submit, in this particular example, this will place a 1 under 9 on the spreadsheet and 1 under 17 on the spreadsheet.
(The spreadsheet has 8,9,10,11,12 etc running horizontally)
What i need to do is have ones underneath the hours in between the users selction, in this example, 10,11,12,13,14,15 & 16.
I assume the easiest way to do this is
Dependant on which ComboBox value i have outputting last, this would then be followed by an autofill command.
What i can't workout is how to then turn this into an autofill command to put the required ones in as described earlier.
Any ideas, appreaciate your help as always
Thanks
Ben
Need some help with either an XltoLeft or XltoRight Autofill
I have a userform where the user selects their shift start time and then their shift end time both from inbuilt combobox to ensure uniformity.
For example:
Shift Start Time 9
Shift End Time 17
On pressing submit, in this particular example, this will place a 1 under 9 on the spreadsheet and 1 under 17 on the spreadsheet.
(The spreadsheet has 8,9,10,11,12 etc running horizontally)
What i need to do is have ones underneath the hours in between the users selction, in this example, 10,11,12,13,14,15 & 16.
I assume the easiest way to do this is
Code:
Range(ActiveCell, ActiveCell.End(xlToLeft)).Select
or
Range(ActiveCell, ActiveCell.End(xlToRight)).Select
Dependant on which ComboBox value i have outputting last, this would then be followed by an autofill command.
What i can't workout is how to then turn this into an autofill command to put the required ones in as described earlier.
Any ideas, appreaciate your help as always
Thanks
Ben