theebookzoo
New Member
- Joined
- Aug 12, 2008
- Messages
- 16
I have two tabs in my worksheet Dashboard and Details.. in the Dashboard I have rows that look like:
AMC 78
ANG 152
These are all links to the Details tab. So if you click on say 78, it takes you to the Details tab and filters on the col1 (ie. AMC), and gives you all AMC items....
What should happen is that the TOTAL (ie. 78 or 152) in the SUmmary should correspond to the DETAIL tab (ie. 78 lines of AMC data, or 152 lines of ANG data)...
Need more info let me know... I gotta get this thing out....
My Code looks like the below:
<!-- / message --><!-- BEGIN TEMPLATE: ad_showthread_firstpost_sig --><!-- END TEMPLATE: ad_showthread_firstpost_sig --><!-- edit note -->
AMC 78
ANG 152
These are all links to the Details tab. So if you click on say 78, it takes you to the Details tab and filters on the col1 (ie. AMC), and gives you all AMC items....
What should happen is that the TOTAL (ie. 78 or 152) in the SUmmary should correspond to the DETAIL tab (ie. 78 lines of AMC data, or 152 lines of ANG data)...
Need more info let me know... I gotta get this thing out....
My Code looks like the below:
Rich (BB code):
Private Sub Worksheet_FollowHyperlink(ByVal Target As Hyperlink)
Rich (BB code):
' follow the target link
Application.EnableEvents = False ' stop recursive call
Target.Follow
Application.EnableEvents = True
' Get the row index
Dim rowNum As Integer
rowNum = ActiveCell.Row 'Target.Parent.Row
' Get the clicked column
Dim columnNumber As Integer
columnNumber = ActiveCell.Column ' Target.Parent.Column
' get the name of the organization.
Dim orgName As String
orgName = Cells(rowNum, 1)
' Filter on the org
Sheet23.Range("A1:O1").AutoFilter
Sheet23.Range("A1:O1").AutoFilter Field:=1, Criteria1:=orgName
' now we need to figure out the column stuff
If columnNumber = 3 Then
' Z1 is missing
Sheet23.Range("A1:O1").AutoFilter Field:=10, Criteria1:="X"
ElseIf columnNumber = 5 Then
' p7 PM is missing
'Sheet23.Range("A1:K1").AutoFilter Field:=12, Criteria1:="X"
ElseIf columnNumber = 6 Then
' p7 POC missing
Sheet23.Range("A1:O1").AutoFilter Field:=11, Criteria1:="X"
ElseIf columnNumber = 7 Then
' P34 missing
'Sheet23.Range("A1:O1").AutoFilter Field:=13, Criteria1:="X"
ElseIf columnNumber = 8 Then
' G13 missing
Sheet23.Range("A1:O1").AutoFilter Field:=12, Criteria1:="X"
ElseIf columnNumber = 9 Then
' MS missing
Sheet23.Range("A1:O1").AutoFilter Field:=13, Criteria1:="X"
ElseIf columnNumber = 13 Then
' S42 missing
Sheet23.Range("A1:O1").AutoFilter Field:=14, Criteria1:="X"
ElseIf columnNumber = 14 Then
' A7 missing
Sheet23.Range("A1:O1").AutoFilter Field:=15, Criteria1:="X"
End If
End Sub
Last edited by a moderator: