UiPath Documentation
activities
latest
false
Productivity activities

Match Function Workbook (preview)

Match Function Workbook activity that finds the relative position of a value within a range using the Excel MATCH function.

UiPath.Excel.Activities.MatchFunction

Description​

Finds the relative position of a value within a range, using the Excel MATCH function. This is the cross-platform equivalent of the Match Function Windows activity.

Note:

This activity does not support .xls files.

Project compatibility​

Windows | Cross-platform

Properties​

Common​

  • DisplayName - The name displayed for the activity in the Designer panel.

Input​

  • File - The full path of the resource workbook. To switch to a local path, select the plus icon, and then Use Local File. The current field changes to File (local path), where you can provide the full path of the workbook.
  • SheetName - The name of the sheet from the workbook.
  • Range - The range to search in. This field is required.
  • Lookup Value - The value to search for. This field is required.
  • Match Type - Select how the lookup value is matched against the range. The default value is 1 (largest value less than or equal to the value to match). You can choose from the following options:
    • 1 (largest value less than or equal to the value to match) - Finds the largest value that is less than or equal to the lookup value. The range must be sorted in ascending order.
    • 0 (first value exactly equal to the value to match) - Finds the first value that is equal to the lookup value. The range can be in any order.
    • -1 (smallest value greater than or equal to value to match) - Finds the smallest value that is greater than or equal to the lookup value. The range must be sorted in descending order.

Options​

  • Password - The password of the workbook, if necessary.

Output​

  • Position - The 1-based position of the match within the range, stored as an Int32 variable. The value is -1 if the activity doesn't find a match.

Use Workbook​

  • Workbook - The existing workbook to use instead of a file path.

Notes​

  • Position is relative to the range, not to the sheet. For example, a match on the third cell of the range returns 3, wherever the range starts on the sheet.
  • Range must refer to the sheet in SheetName. A range that includes a sheet name, such as Sheet2!A2:A100, is not supported and causes an error.
  • A whole-column or whole-row range, such as A:A, is limited to the used range of the sheet.
  • The activity fails with an error if Range is empty or Lookup Value is null.
  • Description​
  • Project compatibility​
  • Properties​
  • Common​
  • Input​
  • Options​
  • Output​
  • Use Workbook​
  • Notes​

Was this page helpful?

Connect

Need help? Support

Want to learn? UiPath Academy

Have questions? UiPath Forum

Stay updated