Skip to main content
Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Answered

PVA Return Sharepoint Files unable to Return Items

(0) ShareShare
ReportReport
Posted on by 508

A little frustrated, trying to get this flow working all day.  I was trying to use @renatromano flow so I could replicate but but cannot get anything to return.  I am trying to crate a PVA bot that would return a list of files based off of search input.  So I would ask the bot to look for files inside of sharepiont. I would enter a text search, which could be a partial of the file OR Contains.  And then the bot would reutrn a list of files and their corresponding folder if possible.  Can someone kindly look at my flow to see where I am going wrong.  12 hours of work and still not results. Please help! 

1. 

VeeLearnMSFT_0-1651453584108.png

2. 

VeeLearnMSFT_1-1651453662347.png

Nothing is returing back.  I spent all day trying to get this to work. Im not ready to throw in the towel as I know I am way too new at this. I am stuck and I cannot get a search to work to return files.

 

VeeLearnMSFT_2-1651453884140.png

 

  • VeeLearnMSFT Profile Picture
    508 on at
    Re: PVA Return Sharepoint Files unable to Return Items

    Nevermind, I figured it out..Apparently when the screen resolutions drops below a certain threshold it gets rid of dynamic content.  

  • DamoBird365 Profile Picture
    8,942 Microsoft Employee on at
    Re: PVA Return Sharepoint Files unable to Return Items

    Hi @VeeLearnMSFT 

     

    Genuinely, I think Power Automate is being upgraded! I was having problems too tonight. It looks like experimental features are being made permanent. Try zooming out and the expression builder may appear. Otherwise try tomorrow.

     

    Damien

  • VeeLearnMSFT Profile Picture
    508 on at
    Re: PVA Return Sharepoint Files unable to Return Items

    Almost there but I have no idea why my dynamic functions are not showing up in the teams environment. Usually when I click in any of those areas in flow.microsoft.com and there are possibilities of dynamic functions a window shows up to the side.  It doesnt come up anywhere.  I am not sure why.  

     

    Is there another way I can get the decodeUri.... function?

     

     

    VeeLearnMSFT_1-1651697129226.png

     

  • DamoBird365 Profile Picture
    8,942 Microsoft Employee on at
    Re: PVA Return Sharepoint Files unable to Return Items

    Hi @VeeLearnMSFT 

     

    Glad you've cracked it and agreed, @Rhiassuring is doing a great job here too.

     

    I think you inadvertently added a - to the markdown which is quite picky and this has resulted in the full URL being displayed.  Take a look at my example.

     

    DamoBird365_0-1651695557442.png  

     

    You need to add a new line to your string for formatting.  @tom_riha's blog shows you how to add a return line How to add new line ('\n') to a string in Power Automate (tomriha.com) with the expression decodeUriComponent('%0A').

     

    I've added folder path to the name in the append to string and also a - at the start of the line, which is a bullet mark in markdown. Use markdown to format Power Automate approvals - Power Automate | Microsoft Docs

     

    This results in the following output:

    DamoBird365_1-1651695752111.png

    Good luck!

     

    Damien

     

     

  • VeeLearnMSFT Profile Picture
    508 on at
    Re: PVA Return Sharepoint Files unable to Return Items

    First of all a big thank you @Rhiassuring and @DamoBird365.  You guys do not know how happy I am. I know it doesnt take much right?  You guys didnt give up on my issue and you have been so gracious with your time.  I honestly appreciate you guys so much and I wish I could clone you.  I have been struggling days at this and finally we got it to work all thanks to you guys.

     

    After reading everything you guys have said again it convinced me to start over.  I deletd the bot, I deleted the flows, I put on a new face and wouldnt you know it....IT WORKS NOW. I have no idea why it was giving me so many errors.  I have no idea what changed but by starting over it did something.  I did however add the closing loop on the end of the bot trigger flow.  I added an eding message box and put in the closing output variable.  Perhaps this was one of those things that added to it.  Doing this for the very first time certainly helped me learn alot from you guys.

     

    if I may one last question, You can see that the bot out puts some data but its a bit messy:  Can I force it to give the out put in a cleaner format.  Maybe like the subfolder and the file name.  So in this case it would be [2022 CY2022 Compensation - 2022 BenchmarksBencharks] the name but the link being only the folder name it is in, and I mean the subfolder because the root folder would be like the Year 

     

    So in this case would be just: 

    VeeLearnMSFT_2-1651691290696.png

    and then the file name.  

    Or maybe even add some bullet points?  Not sure what are the format options to put put so its easier to read.

     

     

     

    VeeLearnMSFT_0-1651690863685.png

     

    THANK YOU THANK YOU THANK YOU GUYS..super happy we got this working!

  • DamoBird365 Profile Picture
    8,942 Microsoft Employee on at
    Re: PVA Return Sharepoint Files unable to Return Items

    Hi @VeeLearnMSFT 

     

    Did you crack it?

     

    Damien

  • Verified answer
    DamoBird365 Profile Picture
    8,942 Microsoft Employee on at
    Re: PVA Return Sharepoint Files unable to Return Items

    Hi @VeeLearnMSFT 

     

    I appreciate you tracking me down on Reddit regarding my video https://youtu.be/mfKa4i9yYtY on a DHL ChatBot.  I think you are almost there to be honest.  Rather than using title for the markdown, use Name i.e. filename and that will sort the empty [] I see in your screenshot.  Regarding the 3000 error, I am unsure but having just built this entirely from scratch in 5 mins, this works OK for me.

     

    Here is an example of a working flow:

    DamoBird365_0-1651682617666.png

     

    This is what the PVA map looks like:

    DamoBird365_1-1651682661539.png

     

    And an example conversation:

    DamoBird365_2-1651682691854.png

     

    The only other thing I cannot see from your screenshot is the final message back to the user?  I actually removed that step as a test, so all the PVA does is run the flow and doesn't return a message and mine still runs OK, albeit it doesn't respond.  So I am wondering at what point your PVA fails and returns the error?  You should be able to play it back in the test bot and see where the process fails and possibly share the final part of the PVA map?

     

    Damien

  • VeeLearnMSFT Profile Picture
    508 on at
    Re: PVA Return Sharepoint Files unable to Return Items

    I dont know what else to do. Im at a loss, I have been at it for days and you have been so gracious taking your time to help me but nothing seems to work.  I still get the same error.  

     

    1. 

    VeeLearnMSFT_1-1651662134722.png

     

    2. 

    VeeLearnMSFT_2-1651662146831.png

    3.

    VeeLearnMSFT_4-1651662311436.png

    4.

    VeeLearnMSFT_5-1651662365878.png

    Output from audit:

    VeeLearnMSFT_3-1651662249967.png

     

     

    This is how it is coming to the Return value(s) to Power Virtual Agent:

    VeeLearnMSFT_0-1651662106157.png

     

    VeeLearnMSFT_7-1651662485396.png

     

    Chat Bot:

    1st screenshot:

    VeeLearnMSFT_8-1651662526796.png

    VeeLearnMSFT_9-1651662537587.png

    This is the sharepoint site.

    VeeLearnMSFT_10-1651662840082.png

     

     

  • Verified answer
    Rhiassuring Profile Picture
    8,688 Super User 2025 Season 1 on at
    Re: PVA Return Sharepoint Files unable to Return Items

    WELP - I've just learned something from you, and also from a past @Pstork1 post.

    Just built my first bot, and, figured out the issue here!

    When passing links back to the PVA, you want to use the format of [TITLE](link). 

    Check this out:  https://docs.microsoft.com/en-us/power-automate/approvals-markdown-support#links

    My string looked like this:

    Rhiassuring_3-1651634894013.png

     

     

     

    And here's the output:

    Rhiassuring_2-1651634874448.png

     

    Uh oh, these bots are fun...

    ...oh and $1280 a month apparently. ..WELP.

     

     

     

     

     

  • VeeLearnMSFT Profile Picture
    508 on at
    Re: PVA Return Sharepoint Files unable to Return Items

    I know but I wanted to impress you 😞 so I am passing a text string through the bot which is the name of the file.  The file contains Kadaj in side of it.  It is pulling all instances matching Kadaj string.  But what I dont get is why is it bunching kadaj and the link to the file right next to each other.  I just thought  it was weird and perhaps this is why it stopped.  I mean I see the links being outputed in the body of the return to virtual agent box.  I just dont know why its not returning anything.  

     

    VeeLearnMSFT_0-1651622342120.png

     

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

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 1

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 1