Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Am I doing something wrong here?
Here is my formula:
--------------------------------------------------------------------- Private Sub Worksheet_SelectionChange(ByVal Target As Range) Dim a As Boolean Dim b As Boolean Dim c As Boolean b = Range("Goal1").Value c = Range("Goal2").Value a = False For x = 6 To 53 If c = 0 Then a = False If Cells(x, 3).Value = 1 And a = False Then Range(Cells(x, 13), Cells(x, 13)).Value = "1" Range(Cells(x, 14), Cells(x, 32)).Value = "-" a = True b = b - 1 ElseIf Cells(x, 3).Value = 1 And a = True Then Range(Cells(x, 13), Cells(x, 22)).Value = "-" Range(Cells(x, 23), Cells(x, 23)).Value = "1" Range(Cells(x, 24), Cells(x, 32)).Value = "-" a = False c = c - 1 End If Next x For x = 6 To 53 If Cells(x, 3).Value = 0 Then Range(Cells(x, 13), Cells(x, 32)).Value = "-" End If Next x End Sub --------------------------------------------------------------------- I want it to subtract from Goal1 or Goal2 everytime it runs that par of the program but not subtract from those cells. Can anyone help m with this? Thanks, TyeJa -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Am I doing something wrong here?
Tye,
This looks like your previous post on 6/15. Are you still try to se the team goals ? Charle -- Message posted from http://www.ExcelForum.com |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Am I doing something wrong here?
Because everything is equal right now what I set up on 6/15 works great
I am just trying to tweak it for when one team has more to do than th other team. Sorry about posting again, I just cant figure it out. -TyeJae -- Message posted from http://www.ExcelForum.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
What is wrong? | Excel Discussion (Misc queries) | |||
Insert Calculated Field (wrong Qty*Price = wrong Amount) | Excel Discussion (Misc queries) | |||
What am I doing wrong? | Excel Discussion (Misc queries) | |||
What's wrong with this vb? | Excel Worksheet Functions | |||
What is wrong?? | Excel Programming |