Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
MAN! This is BS! I am an EE with some coding background and i cant
figure this out for my life. here is the code that i am using: Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Target.Count 1 Then Exit Sub If Target.Column = 6 And Target.Row 3 And Target.Row < 256 And Target.Value = "F" Then Worksheets("Test Results").Select Worksheets("Test Results").Cells(2, Target.Row + 1).Select End If If Target.Count 1 Then Exit Sub If Target.Column = 7 And Target.Row 3 And Target.Row < 256 And Target.Value = "F" Then Worksheets("Test Results").Select Worksheets("Test Results").Cells(13, Target.Row + 1).Select End If If Target.Count 1 Then Exit Sub If Target.Column = 8 And Target.Row 3 And Target.Row < 256 And Target.Value = "F" Then Worksheets("Test Results").Select Worksheets("Test Results").Cells(24, Target.Row + 1).Select End If If Target.Count 1 Then Exit Sub If Target.Column = 9 And Target.Row 3 And Target.Row < 256 And Target.Value = "F" Then Worksheets("Test Results").Select Worksheets("Test Results").Cells(35, Target.Row + 1).Select End If If Target.Count 1 Then Exit Sub If Target.Column = 10 And Target.Row 3 And Target.Row < 256 And Target.Value = "F" Then Worksheets("Test Results").Select Worksheets("Test Results").Cells(46, Target.Row + 1).Select End If If Target.Count 1 Then Exit Sub If Target.Column = 11 And Target.Row 3 And Target.Row < 256 And Target.Value = "F" Then Worksheets("Test Results").Select Worksheets("Test Results").Cells(57, Target.Row + 1).Select End If If Target.Count 1 Then Exit Sub If Target.Column = 12 And Target.Row 3 And Target.Row < 256 And Target.Value = "F" Then Worksheets("Test Results").Select Worksheets("Test Results").Cells(68, Target.Row + 1).Select End If If Target.Count 1 Then Exit Sub If Target.Column = 13 And Target.Row 3 And Target.Row < 256 And Target.Value = "F" Then Worksheets("Test Results").Select Worksheets("Test Results").Cells(77, Target.Row + 1).Select End If End Sub I would like to insert a piece of code into each if statement to change the target cell + the next 10 rows in that column to a red font. then change the font back to black (or default) after the selection changes. i have once again given my best shot and the best i can get (once i get passed the runtime errors), is for nothing to happen. Thanks yet again! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Record Macro and Edit Macro options disabled | New Users to Excel | |||
Record New Macro | Setting up and Configuration of Excel | |||
how to record new macro using vba | Excel Programming | |||
Record Macro - Record custom user actions | Excel Programming | |||
how to count/sum by function/macro to get the number of record to do copy/paste in macro | Excel Programming |