Thank you to Bob Phillips for getting me this far.
I am having problems with refining when code runs.
this is the code so far
Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo ws_exit
Application.EnableEvents = False
' I need a further condition then ensures the trigger column is one that needs this done
' the column at row 8 will be marked with another * but hidden with a white font on white
' then to complicate it further the row number must be greater than or equal to 9 and odd
' Finally cell(L3) should indicate a valid row and column with for example the word valid
If IsOdd(Target.Row) Then
If .Value = "*" Then
' This Should run if the user is to choose * from the drop down list
Dim Start_time As String ' Set Shift Start Time
Dim Finish_time As String ' Set Shift Finish Time
Start_time = Inputbox("Start Time", "MANUAL ENTRY MODE 1 of 2") ' Input The Start Time
.Offset(0, 1).Value = Start_time ' Update cell with the entered start value
Finish_time = Inputbox("Finish Time", "MANUAL ENTRY MODE 2 of 2") ' Input The Finish Time
.Offset(0, 2).Value = Finish_time ' Update the cell with the entered Finish time
.Offset(0, 1).Formula = "=VLOOKUP(" & .Address & ",$AY$9:$BB$20,3,FALSE)"
.Offset(0, 2).Formula = "=VLOOKUP(" & .Address & ",$AY$9:$BB$20,4,FALSE)"
Application.EnableEvents = True
Whilst this code works perfectly it does not give me the flexibility of being able to be more specific as to when it runs
I can place a marker in a column (at row 8 for example) which i will simply hide by making it the same colour as its
then the code needs to run only when the row is an odd value ant within a certain range (eg from 9 to 21)
I suspect i need to use the Isodd or iseven syntax but i am struggling as to how
This or a very similar post has
been placed in Mr Excel also but i seem to be unable to access their site cureently so i am unable to link (currently)
As i am TRYING (slowly) to learn as i go PLEASE rather than just fix my issue notate things and hopefully one day i
will be more capable.
Thank you in advance