Thread: [Solved] Need help creating vba code
View Single Post
 
Old 10-12-2019, 05:27 PM
Moot70 Moot70 is offline Windows 10 Office 2019
Novice
 
Join Date: Oct 2019
Location: Oklahoma
Posts: 16
Moot70 is on a distinguished road
Default

i have file I column B & F I want go back forth B & F in color area only

sample B3 than F3 I press enter or tab F3 I press enter than go down to B4 back for until F18 reach F18 I want go back to B3


Thanks You


Moot70

week 1-17 pick them

red color cells is unpick teams. i need code that go through column B and column F pick them

B3 when I press tab or enter key it will goto F3 than goto B4
B4 when I press tab or enter key it will goto F4 than goto B5
B5 when I press tab or enter key it will goto F5 than goto B6
B6 when I press tab or enter key it will goto F6 than goto B7
B7 when I press tab or enter key it will goto F7 than goto B8
B8 when I press tab or enter key it will goto F8 than goto B9
B9 when I press tab or enter key it will goto F9 than goto B10
B10 when I press tab or enter key it will goto F10 than goto B11
B11 when I press tab or enter key it will goto F11 than goto B12
B12 when I press tab or enter key it will goto F12 than goto B13
B13 when I press tab or enter key it will goto F13 than goto B14
B14 when I press tab or enter key it will goto F14 than goto B15
B15 when I press tab or enter key it will goto F15 than goto B16
B16 when I press tab or enter key it will goto F16 than goto B17
B17 when I press tab or enter key it will goto F17 than goto B18
B18 when I press tab or enter key it will goto F18

Blue color cells is unpick teams. i need code that go through column B and column F
wild card & division pick them

B3 when I press tab or enter key it will goto F3 than goto B4
B4 when I press tab or enter key it will goto F4 than goto B5
B5 when I press tab or enter key it will goto F5 than goto B6
B6 when I press tab or enter key it will goto F6

Conf Championship them
B3 when I press tab or enter key it will goto F3 than goto B4
B4 when I press tab or enter key it will goto F4

Super Bowl Pick Them
B3 when I press tab or enter key it will goto F3

I have this code

Private Sub Worksheet_Change(ByVal Target As Range) Dim tabArray As Variant
Dim i As Long
tabArray = Array("B3", "F3", "B4", "F4", "B5", "F5", "B6", "F6", "B7", "F7", "B8", "F8", "B9", "F9", "B10", "F10",

"B11", "F11", "B12", "F12", "B13", "F13", "B14", "F14", "B15", "F15", "B16", "F16", "B17", "F17", "B18", "F18")
Application.ScreenUpdating = False
For i = LBound(tabArray) To UBound(tabArray)
If tabArray(i) = Target.Address(0, 0) Then
If i = UBound(tabArray) Then
Me.Range(tabArray(LBound(tabArray))).Select
Else
Me.Range(tabArray(i + 1)).Select
End If
End If
Next i
Application.ScreenUpdating = True
End Sub

The code that is above is no working way I want to work. It should B3,F3 down to B18,F18

I need help fix the code to make it work way I want work


TY
Thomas

picture give you visible
Attached Images
File Type: jpg PICK THEM WEEK 1 UNPICKED.jpg (122.8 KB, 47 views)
File Type: jpg PICK THEM WEEK 1 PICKED.jpg (138.0 KB, 46 views)
Attached Files
File Type: xlsm NFL PICK THEMS.xlsm (108.8 KB, 12 views)
Reply With Quote