I have an issue regarding extracting a portion of a string.
I’m using the ‘Use Application/Browser’ activity and am extracting the Output Element to a UiElement variable titled outputWindow.
When I output outputWindow to a log message activity using outputWindow.Selector.ToString, the details of the extracted variable are: (less than symbol)wnd app=‘saplogon.exe’ cls=‘SAP_FRONTEND_SESSION’ title=‘List 0002 - Personal Data’ /(more than symbol)
I am wanting to extract what’s after title=, and only what’s between the inverted commas; e.g. List 0002 - Personal Data.
Could someone please tell me how to do this? I’ve looked at the string manipulation article, but I’m just not getting it.
@Clintonnn Assign this below code to a string,
TitleVar(Of String type) = System.Text.RegularExpressions.Regex.Match(outputWindow.Selector.ToString,“title=(‘|')([A-z0-9\s-]+)”).Groups(2).Value
And also you can get this value using ‘Get Attribute’ activity.