Demo Project using JSON Activities

The URL of the demo project is given below where users can learn about these activities in a better manner. 

Steps:

  1. Create a sample JSON file within Genie Studio. 
  2. Read the JSON file and assign its contents to a string variable. 
  3. Convert the string variable into a JSON object using the “JSON Deserialize” activity. 
  4. Display the values of the different properties from the JSON file in a message box. 
  5. Create a sample JSON using the “JSON Creator” activity. 
  6. Replace the value of a specific property with a variable. 
  7. Convert the JSON object into a string variable using the “JSON Serialize” activity. 
  8. Write the string variable to a text file. 
Activities Used“Read Text File, JSON Deserialize, JSON Creator, JSON Serialize, Write Text File, Message Box”
Video Link https://www.youtube.com/watch?v=4T7xP66c3RU&list=PLwFA5laAhcEJ7sVztHRNXDdXffy2odMvv&index=18

Sub Activity – JSON

This category allow users to create, manipulate, and process JSON data efficiently in automation workflows. These activities streamline the integration of JSON-based data with other automation components, improving efficiency in data processing.

The JSON category has the following sub activities:

JSON Creator: This activity returns a JObject that encodes a string object. It accepts a string in JSON format and can map variables or values to the respective nodes in the string.

Input Properties:

  • Options: Creates a string in JSON format. It allows you to map or assign values to the corresponding nodes in the string.

Output Properties:

  • JSONObject: The resulting JSON object that is stored in an object variable.

JSON Deserialize: This activity accepts a string in JSON format and converts it into a JSON Object.

Input Properties:

  • JSONString: The JSON string that you want to convert into an object.

Output Properties:

  • JSONObject: The resultant JSON object is stored in an Object variable.

JSON Serialize: This activity converts an input Object into a string in JSON format.

Input Properties:

  • Object: The JSON Object that you want to serialize.

Output Properties:

  • JSONString: The resultant JSON string is stored.

Demo Project using Dictionary Activities

The URL of the demo project is given below where users can learn about these activities in a better manner. 

Steps:

  1. Create a Dictionary using the “Build Dictionary” activity. 
  2. Retrieve the values from the dictionary by using the corresponding keys. 
  3. Add a new key/value pair to the dictionary using the “Add to Dictionary” activity. 
Activities Used“Build Dictionary, Add to Dictionary, Message Box”
Video Link https://www.youtube.com/watch?v=M8CUKaF6hEk&list=PLwFA5laAhcEJ7sVztHRNXDdXffy2odMvv&index=17

Sub Activity – Dictionary

Dictionary includes activities for working with key-value pairs, allowing efficient storage, retrieval, and manipulation of data where each value is associated with a unique key.

The Dictionary category has the following sub activities:

Add To Dictionary: This activity is used to add key-value pairs to a dictionary.

Input Properties:

  • Dictionary– Specify the dictionary variable to which the key-value pairs will be added.
  • Key– Specify the key to be added to the dictionary.
  • Value– Specify the value to be associated with the given key in the dictionary.
  • IsOverwrite– Select this check box to overwrite the value if the key already exists in the dictionary.

Build Dictionary: This activity is used to create a new dictionary for storing keys and values.

Input Properties:

  • Build– Add the desired number of keys and their corresponding values to the dictionary.

Output Properties:

  • Dictionary– Stores the added key-value pairs in the dictionary variable.

Sub Activity – DateTime

DateTime includes activities for manipulating and formatting date and time values, allowing you to perform operations such as calculating time differences, adding/subtracting dates, and formatting date/time outputs.

The DateTime category has the following sub activities:

Add DateTime: This activity allows the user to add a Date and Time by giving an interval specified by the user in the properties section.

Input Properties:

  • Interval– The time/date interval to add.
  • DateTime– Date time to which number is to be added.
  • Number– The number of intervals to add to the date. Positive values give future dates, while negative values give past dates.

Output Properties:

  • Added DateTime– The variable that stores the added DateTime value.

Current DateTime: This activity gets the Current Date Time of a Specified TimeZone.

Input Properties:

  • TimeZone– Select the standard time zone.

Output Properties:

Current DateTime– The variable that stores the standard time for the selected time zone.

DateTime Difference: This activity can be used to find the difference between the specified Start and End datetime.

Input Properties:

  • Interval– Select the interval to calculate the DateTime difference. Or Select the part to return for the DateTime difference (e.g., year, month, day).
  • StartDate – Specify the starting DateTime for the difference calculation.
  • EndDate– Specify the ending DateTime for the difference calculation.

Output Properties:

  • Date Difference– The variable that stores the calculated difference between two DateTime values.

DateTime Part: This activity is used to get a part of the date.

Input Properties:

  • Interval– Select the specific part of the DateTime argument to return (e.g., year, month, day).
  • DateTime– The DateTime from which the specified part is to be extracted.

Output Properties:

  • DatePart– The variable that stores the integer value of the DateTime part.

Format DateTime: This activity converts a specific date-time into any format of the user’s choice in the form of an output string variable.

Input Properties:

  • Value– Enter the DateTime value to be formatted.
  • Format– Select the desired DateTime format.

Output Properties:

  • Formatted DateTime– The variable that stores the formatted DateTime.

Demo Project using DataTable Activities (Part 2)

The URL of the demo project is given below where users can learn about these activities in a better manner.  

Steps:

  1. Create a sequence for the DataTable Filter activity 
    • Create a sample DataTable using the Build DataTable activity 
    • Filter its rows by specifying a condition in the DataTable Filter activity 
    • Preview the filtered DataTable. 
  2. Create another sequence for the Merge DataTable activity. 
    • Create two separate DataTables with identical column names 
    • merge the two DataTables using the Merge DataTable activity 
    • Preview the merged DataTable. 

Activities Used“Build DataTable, DataTable Filter, Merge DataTable, Preview DataTable”
Video Linkhttps://www.youtube.com/watch?v=c_6m6Hl0AcM&list=PLwFA5laAhcEJ7sVztHRNXDdXffy2odMvv&index=16

Demo Project using DataTable Activities (Part 1)

The URL of the demo project is given below where users can learn about these activities in a better manner.  

Steps:

  1. Create a DataTable with sample data and then preview that DataTable. 
  2. Add new rows and columns to an existing DataTable 
  3. Clear the data from the DataTable. 

Activities Used“Build DataTable, Preview DataTable, Add Data Row, Add Data Column, Clear DataTable”
Video Linkhttps://www.youtube.com/watch?v=hXomtHpmBS4&list=PLwFA5laAhcEJ7sVztHRNXDdXffy2odMvv&index=15

Demo Project using Collection Activities

The URL of the demo project is given below where users can learn about these activities in a better manner.

Steps:

  1. Create an ArrayList using the “Create a Collection” activity. 
  2. Add an item to the collection. 
  3. Check if the item exists in the collection: 
    • If the item exists: 
      • Remove the specific item from the collection. 
      • Loop through the collection and display the remaining items. 
    • If the item does not exist: 
      • Display a message: “Item does not exist”. 

Activities Used“Create Collection, Add Items, Item Exists, Remove Items, For Each, Decision, Message Box”
Video Link https://www.youtube.com/watch?v=QBVu7haEwJw&list=PLwFA5laAhcEJ7sVztHRNXDdXffy2odMvv&index=14

Sub Activity – Collection

Collection includes activities for managing and manipulating data structures such as lists, dictionaries, and arrays to store and process multiple values efficiently.

The Collection activity has the following sub activities:

Add Items: This activity is used to add an array of items to a specified collection.

Input Properties:

  • Collection– The variable that holds the collection items. Or Variable storing collection items.
  • Items– Array of items added to the collection. Or Array of items in the collection.

Create Collection: This activity is used to create a new collection of an ArrayList data type.

Output Properties:

  • Collection– The variable that holds the collection items. Or Variable storing collection items.

Item Exists: This activity is used to check if the specified item exists in the collection or not.

Input Properties:

  • Collection– The variable that holds the collection items. Or Variable storing collection items.
  • Items– Array of items to check in the collection.

Output Properties:

  • Exists– Boolean variables which indicate whether the array of items exists or not.

Remove Items: This activity is used to delete an array of items from a collection.

Input Properties:

  • Collection– The variable that holds the collection items.
  • Items– Array of items to remove from the collection.