VBA code for knowing the loacation each selected cells in a filtered sheet

michel levy 1 Reputation point

Hi all,
Can anyone help me please.
when a user selects a range in a filtered sheet and press on a 'do something button'
I want to know the location of only the selected cells within that range

Dim Rng as Range
Dim MM_tbl As ListObject
Set Rng=Selection

for Each Rng in application.selection

 ' is a cell is in a selection mode 
 if MM_tbl.range(rng.row,rng.column).SpecialCells(xlCellTypeVisible)=selected then....


Thanks a lot

Microsoft Teams Development
Microsoft Teams Development
Microsoft Teams: A Microsoft customizable chat-based workspace.Development: The process of researching, productizing, and refining new or existing technologies.
2,731 questions
0 comments No comments
{count} votes