How to Print the Current Date in UiPath


✅ How to Print the Current Date in UiPath (With Example)

 

🟦 Step 1: Create a Variable

In the workflow, a variable named name is created to store the current date.

  • Variable Name: name

  • Variable Type: DateTime

  • Scope: Main (or as required)

You can create it in two ways:

  1. Through the Variables panel, or

  2. Press Ctrl + K in the Assign activity and enter the variable name.


🟦 Step 2: Assign Today’s Date

Use the Assign activity:

  • To: name

  • Value: Now()

This assigns the current system date and time to the variable.

✔️ Now the variable name holds something like:
10/11/2025 17:32:10


🟦 Step 3: Display the Date in Short Format

Use a Log Message activity to print the date.

  • Message:

    name.ToShortDateString
    

This converts the DateTime value to a readable short date such as:
10/11/2025

  • Log Level: Info


✅ Output

When you run the workflow in Debug mode, you’ll see something like this in the Output panel:

test execution started
10/11/2025
test execution ended in: 00:00:01

Your Log Message prints only the formatted date, just as shown in the image.


🟦 Why Use ToShortDateString?

Methods like ToShortDateString ensure you display only the date part without the time.
Here are a few useful alternatives:

MethodOutput Example
ToString("dd-MM-yyyy")11-10-2025
ToLongDateStringSaturday, 11 October 2025
ToShortDateString10/11/2025

✅ Summary

Using a variable with Now() and a simple Log Message, you can easily print the current date in any UiPath workflow. The image clearly shows:

  1. Assignname = Now()

  2. Log Messagename.ToShortDateString

Perfect for logging, reporting, or timestamping automations!

Let me know if you’d like this turned into a Markdown post or published style content!

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