cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Aria
Frequent Visitor

How to detect a file in Azure blob storage from PowerApps

Hi ,

From powerapps I want to detect if a file exists in a AzureBlobSotrage such that I can use it to show  the stautus of  file upload from PowerApps to AzureBlobStorage.

The files are created on AzureblobStorage as shown below:


ForAll(Fotos;
AzureBlobStorage.CreateFile(path;fotoId& ".jpg";foto)
);;

Unfortuantly I can not use a variable to get the information about the uploaded file when I use ForAll(...) , and I can not use the following 
ForAll(Fotos;
UpdateContext({uploadedFile:AzureBlobStorage.CreateFile(path;fotoId& ".jpg";foto)})
);;

1 ACCEPTED SOLUTION

Accepted Solutions
yashag2255
Dual Super User II
Dual Super User II

Hi @Aria 

 

If you want to check if a file exist in the specific container on the Azure Blob Storage, you can use the below expression:
 
If("PDF File.pdf" in AzureBlobStorage.ListFolderV2(LookUp(AzureBlobStorage.ListRootFolderV2().value,DisplayName = "testt").Id).value.DisplayName,"Exist","Doesnot Exist")
 
Here, first argument(PDF File.pdf) is the name of my file. testt is the name of container.MicrosoftTeams-image (7).png

 

Hope this Helps!
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

2 REPLIES 2
yashag2255
Dual Super User II
Dual Super User II

Hi @Aria 

 

If you want to check if a file exist in the specific container on the Azure Blob Storage, you can use the below expression:
 
If("PDF File.pdf" in AzureBlobStorage.ListFolderV2(LookUp(AzureBlobStorage.ListRootFolderV2().value,DisplayName = "testt").Id).value.DisplayName,"Exist","Doesnot Exist")
 
Here, first argument(PDF File.pdf) is the name of my file. testt is the name of container.MicrosoftTeams-image (7).png

 

Hope this Helps!
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

Aria
Frequent Visitor

Hi 

Thank you very much for your answer !
I used your suggestion and it solved the problem.

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

PA Community Call

Power Apps Community Call

Next call is happening on April 21st at 8a PST.

MBAS Carousel

Sign up for our May 4th event!

May the fourth be with you, join us online!

secondImage

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Top Solution Authors
Top Kudoed Authors
Users online (41,387)