I have two blocks of code.
<TabItem Header="{materialDesign:PackIcon Kind=Bank, Size=24}"
Style="{StaticResource MaterialDesignNavigationRailTabItem}"
ToolTip="Example">
and
<Button Header="{materialDesign:PackIcon Kind=Bank, Size=24}"
Style="{StaticResource MaterialDesignNavigationRailTabItem}"
ToolTip="Example">
I to select the ToolTip="Example" part and replace it. However, I only want to select the ToolTip that is inside the TabItem block. I can select it with:
ToolTip\=\"(.*?)\"
That selects the one in the Button block as well. I used this StackOverflow Question to try and solve my issue, but I could not figure out how to make it work with a ".*".
So my criteria is:
- Must begin with '<TabItem'
- Must contain 'ToolTip=".*"'
- Must end with ">"
Is what I am trying to achieve possible? If so, how could I achieve this?