Is there a way to determine what element in a stackpanel was clicked on? Like an index of a child or something? For example:
<StackPanel x:Name="Menu" MouseLeftButtonDown="StackPanel_MouseLeftButtonDown" HorizontalAlignment="Left" Margin="10,0,0,0" Orientation="Horizontal">
<Border BorderBrush="#FF014e92" BorderThickness="1,0,0,0">
<Rectangle x:Name="button1" Fill="#FF4c87b3" Width="100" Height="100" />
</Border>
<Border BorderBrush="#FF014e92" ...
Go to the complete details ...