Hi @roman.markman
Its a good question. Considering the flow of this assignment, it works like this.
Just some background first
Init - Initializes the application and makes it ready
GetTransationData - Here, you pass the Transaction Number (which should be 1 initially), and checks whether that page is available just like you mentioned. Here, in the acme system, by default, you are already in page 1 in the work items. Though you are in page 1, still you need to check whether that page already exists. So, the selector you are using for that should be changed a bit actually. So, in GetTransactionData Element exists activity, use this selector.
"<html title='ACME System 1 - Work Items' /><webctrl aaname='" + in_TransactionNumber.ToString + "' tag='LI' />"
This selector returns the page availability irrespective of whether its the currently displayed page or not.
Going to Process state - Using the same transaction number, you perform a click activity to navigate to that page. now, Since we are already in page 1, actually we cannot click on that because that item is disabled. But with this selector, you can pass through that step quite easily. So, for the click activity of the Process state, use the below selector.
"<html title='ACME System 1 - Work Items' /><webctrl aaname='" + in_TransactionItem + "' tag='LI' />"
It is actually the same selector
So this way, you also check whether the first page is available, and performs the click and then do the data scraping. Once the process is done, the execution process executes a xaml file called SetTransactionStatus.xaml. This is where the TransactionNumber variable is incremented by 1. So once it gets here, if the transaction number is 1, it increments to 2. then again it goes to GetTransactionData and checks whether page 2 is available. like wise, it goes on until you finish iterating to all the pages
So… you should start with 1, and using the correct selector is the key here
Hope it helps!!
if this helps, please mark the answer as the solution so it can help others understand this flow