Skip to main content

Posts

Showing posts from September, 2024

What is a dictionary variable in UiPath RPA?

Dictionary variables (Dictionary<TKey, TValue>) are collection type of variables of (key, value) pairs, in which the keys are unique. Think of the Address Book in your mobile phone, where each entry has corresponding data (name, phone number(s), email address, etc). The data types for both keys and values have to be chosen when the variable is declared. Data types within dictionaries can be any of the supported variables (String, Int32, etc) including Dictionary<TKey, TValue>. The operations that are most often associated with dictionaries are: Adding and deleting (key, value) pairs. Retrieving the value associated with a key. Re-assigning new values to existing keys. Methods for working with dictionary variables: Initialization As in the case of list variables, dictionary variables need to be initialized as well. For example, if we want to initialize a dictionary of String type of key and String type of value, we can add new Dictionary(Of String, String) inside the Default...

About lists and arrays in UiPath RPA

What is a 'List' variable type? The List<T>  is a data structure part of the System.Collections.Generic namespace consisting of objects of the same data type. The '<T>' represents the type of elements in the list, for example strings or integers. Each object has a fixed position in the list, and thus it can be accessed by the specific index. Additionally, it provides methods for searching, sorting, and manipulating lists. What is an 'IList' variable type? The IList is actually an Interface. In other words, it is a collection of objects that can be accessed individually by their specific indexes. As in the case of List, the '<T>' represents the type of elements in the list. The IList<T> generic interface is a descendant of the ICollection<T> generic interface and is the base interface of all generic lists. Both List and IList type of variables can be initialized with 'new list (of...)'. For example, if we have a List ...

VB.Net String Functions in UiPath RPA

String.Concat – Concatenates one or more instances of string or string representation of objects. Expression: String.Concat (VarName1, VarName2) Output datatype: String Contains – Checks whether a specified substring occurs within a string and returns either true or false. Expression: VarName.Contains (“text”) Output datatype: Boolean String.Format – Converts the value of objects to strings and inserts them into another string. Expression: String.Format(“{0} is {1}”, VarName1, VarName2) Output datatype: String IndexOf – Returns the index position of the first occurrence of a specified character or a substring. Expression: VarName1.IndexOf(“a”) Output datatype: Int32 LastIndexOf – Returns the index position of the last occurrence of a specified character or a substring. Expression: VarName1.LastIndexOf("author") Output datatype: Int32 String.Join – Concatenates the elements in a collection using the specified separator and displays them as a String. Expression: String.Join(“|”...