ndjustin20
Board Regular
- Joined
- May 25, 2011
- Messages
- 69
Hello Everyone !!!!
I have a strange issue and it only came about when I switched to using office 2010. I have a worksheet with several macros built in using visual basic. When I click on a button the macro runs this code:
Here is the code for FindNeedToRenew
Then to remove all filters I run this code which is another button/macro:
The code does exactly what I want it to do but for some reason now it takes all of my text boxes at the top and squishes them into the first column and row. It never did this before with earlier versions so I'm at a loss as to why it is happening now. I can email the form as I don't see a way to upload anywhere or maybe I'm missing that option somewhere? The text boxes at the top are thrown values depending on what is clicked on the worksheet and are currently set to not move or resize with cell expansion/contraction. Any help would be greatly appreciated as I'm just about bald LOL
Justin
I have a strange issue and it only came about when I switched to using office 2010. I have a worksheet with several macros built in using visual basic. When I click on a button the macro runs this code:
Code:
Sub findWithin60Days()
Dim i%
For i = 1 To 300
Range("E" & i).Interior.Color = RGB(197, 190, 151)
If IsDate(Range("E" & i).Value) Then
If Range("E" & i).Value <> "" Then
If Range("E" & i).Value - Date < 60 Then
Range("E" & i).Interior.Color = RGB(112, 48, 160)
End If
End If
End If
Next i
Call FindNeedToRenew
End Sub
Here is the code for FindNeedToRenew
Code:
Sub FindNeedToRenew()
ActiveSheet.Range("$A$1:$T$300").AutoFilter Field:=5, Criteria1:=RGB(112, 48, 160), Operator:=xlFilterCellColor
ActiveSheet.Range("2:7").Rows.Hidden = False
End Sub
Then to remove all filters I run this code which is another button/macro:
Code:
Sub RemoveFilter()
If ActiveSheet.AutoFilterMode = True Then ActiveSheet.AutoFilterMode = False
End Sub
The code does exactly what I want it to do but for some reason now it takes all of my text boxes at the top and squishes them into the first column and row. It never did this before with earlier versions so I'm at a loss as to why it is happening now. I can email the form as I don't see a way to upload anywhere or maybe I'm missing that option somewhere? The text boxes at the top are thrown values depending on what is clicked on the worksheet and are currently set to not move or resize with cell expansion/contraction. Any help would be greatly appreciated as I'm just about bald LOL
Justin