web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id : jQOs1mmcOmCPRjf7p3cv+k
Power Automate - Power Automate Desktop
Unanswered

I can't rename a file using variables

Like (0) ShareShare
ReportReport
Posted on 24 Jun 2024 18:15:20 by

I'm trying to copy a file and then rename it "dd/MM", however it only seems to work when i use direct text such as "testing" but when i try to use the Formatted date variable to use today's date it won't work, it says "Directory not found" any idea why it might be?

I have the same question (0)
  • NathanAlvares24 Profile Picture
    1,694 Moderator on 24 Jun 2024 at 18:45:32
    Re: I can't rename a file using variables

    Hi @HANNML !

     

    This is actually a Power Automate Desktop question. I have already moved it to the desired location.

     

    Anyways, I do hope you know that a file cannot contain '/' or some other characters like:

    NathanAlvares24_0-1719254164536.png

     

    So instead try this action:

    NathanAlvares24_1-1719254341787.png

    Put this action between 2 and 3 actions:

    NathanAlvares24_2-1719254396620.png

     

    The configuration of the "Replace text" action:

    NathanAlvares24_3-1719254478148.png

     

    Then use this variable "Replaced" in the "Rename file(s)" action of the section, "New File name".

    NathanAlvares24_0-1719254809740.png

     

    I hope this helps.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

MS.Ragavendar – Community Spotlight

We are honored to recognize Ragavendar Swaminatha Subramanian as our September…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 736 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 396 Moderator

#3
Power Apps 1919 Profile Picture

Power Apps 1919 339

Last 30 days Overall leaderboard