How to create a variable and pass default value in Uipath?

In UiPath, variables are created in the Variables panel and you can assign a default value directly. Here’s how:

✅ 1. Create a Variable

There are two ways:

Method 1: From the Variables Panel

  1. Open your workflow (e.g., sequence, flowchart).

  2. At the bottom, click the Variables tab.

  3. Click Create Variable (or press Ctrl + K inside an activity field).

  4. Set:

    • Name (e.g., myText)

    • Variable Type (e.g., String, Int32, Boolean, etc.)

    • Scope (where it can be used)

Method 2: Using Ctrl + K

  1. Click a property in an activity (like Input or To).

  2. Press Ctrl + K

  3. Type a variable name → UiPath will auto-create it.


✅ 2. Assign a Default Value

You can add the value while creating or after:

 

  • In the Default column of the Variables panel, enter the value.

    • String → "Hello"

    • Integer → 10

    • Boolean → True or False

    • DateTime → Now or New DateTime(2025,1,1)

    • Array/List → {"A","B","C"}

 

Example:

Leave a Reply

Your email address will not be published. Required fields are marked *

Company

Hello! I’m a passionate automation enthusiast with a background in Python programming and UiPath automation. With several years of experience in the insurance industry, I’ve witnessed firsthand the challenges organizations face in streamlining processes and managing data efficiently.

Features

Most Recent Posts

eBook App for FREE

Lorem Ipsum is simply dumy text of the printing typesetting industry lorem.

Category

Unlock the synergy of Python and UiPath to elevate your automation projects 

My skills

Automation

Illustrator designing

Web developing

Content writing

Learn from ME

Uipath Automation

Python programing

latest trends in IT

Designs using illustrator

Purchase

Automation projects

Graphic designs

web Boiler plates

Newsletter

Help

Copyright

Privacy Policy

© 2024 created by SubinSuresh