QuestionQ74

VerifiedVariables and Arguments

A developer created the dt_Users data table shown in the following exhibit:

Question Image

After scraping data from a web application, the developer wants to assign every row in the dt_Users variable to a Dictionary<string, string> variable, DictUsers. Within a For Each Row activity, the developer also wants user IDs assigned as keys and usernames assigned as values.

Question Image

How should the Assign activity be configured?

Explanation

A dictionary entry is assigned using the form dictionary(key) = value. The User ID column is at index 1 and must be the key, while the UserName column is at index 0 and must be the value. Therefore, the assignment is DictUsers(CurrentRow(1).ToString) = CurrentRow(0).ToString.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!