smart timetable - find cell and insert 'value'

desmond_

Board Regular
Joined
Jan 4, 2017
Messages
59
dear experts,

i was thinking about an automatized timetable which could look like this
i insert the month/year in the first column and the related cell will be entered with whatever value 'x'

insert month here010203040506070809101112
01'x'
08'x'

<tbody>
</tbody>

since INDEX(MATCH) is somehow the reversed function i guess this should be possible.
i just have no idea how to write the vba code.

do you have some help/suggestions

thanks in advance !
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Assuming that your header is row 1 & Month is col A, try
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
   
   Dim Fnd As Range
   If Target.CountLarge > 1 Then Exit Sub
   If Not Target.Column = 1 Then Exit Sub
Application.EnableEvents = False
   Set Fnd = Rows(6).Find(Target.Value, , xlValues, xlWhole, , , False, , False)
   If Not Fnd Is Nothing Then Target.Offset(, Fnd.Column - 1) = "X"
Application.EnableEvents = True
End Sub
 
Upvote 0
Glad to help & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,215,477
Messages
6,125,037
Members
449,205
Latest member
Eggy66

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top