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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Images wont show on ip...
Power Apps
Answered

Images wont show on iphone

(0) ShareShare
ReportReport
Posted on by 16
Hopefully someone can help me fix my power app.  "AI" has me running in circles lol.  Heads up, this is a slightly long read. 
 
I recently created an enhancement to my power app.  I created a new screen with a form.  the form allows an image to be taken and a few text fields to be filled out.  Copilot suggested I store the captured image in a document library on my sharepoint site, so that's what I did.  Upon submit, the power app creates a unique file name for the image and saves the file name into the excel file (along with the other text fields data). The submit also triggers a power automate flow that saves the image file to the document library using the same filename.
 
The other screen I created is a vertical gallery that displays data from the excel file and pulls the filename of the related captured image to display it in the vertical gallery.  I built this functionality on my laptop using the web version of powerapps because I don't have access to the desktop application.  I also used the power automate flow creator within the power apps software because it seemed easier and more intuitive for me to use.  Long story short, the functionality works flawlessly on my laptop but the vertical gallery will not display the images on my iphone.  Oddly, I can capture and upload images from my iphone successfully to the document library and another user been able to upload them from an iphone as well.  Problem is the iphone will not display the images from the vertical gallery.  Keep in mind, it works flawlessly on a laptop and I've tested with myself and another user.  
 
Copilot is now suggesting different fixes and they seem to be almost like a complete tear down and rebuild of the code.  Coplilot apologized and said that what it had initially suggested was wrong and would not work.  I've tried asking the same question in different ways and copilot is suggesting different fixes so I can only assume that it's guessing at this point.
 
Does anyone know the true fix to this problem?  If you need more details or want to see the code I have then I would be able to provide that.   Hope there's a simple solution to my problem.  Full disclosure, I'm a novice at power apps development, but I built the original app and the site loved it so this enhancement would be another big win for us.  That being said, I would appreciate if a solution can be explained to me in laymans terms because I'm not a developer.
Categories:
I have the same question (0)
  • Verified answer
    WarrenBelz Profile Picture
    153,372 Most Valuable Professional on at
    The issue is that the Mobile version of Power Apps will not resolve a URL-based image unless it is able to do so anonymously (no login required), so a SharePoint based image simply will not work.
     
    You need to link the actual SharePoint Library to the app, store the ID of the relevant image and then display it
    LookUp(
       SPLibrary,
       ID = YourStoredID
    ).'{Thumbnail}'.Large
     
    Please ✅ Does this answer your question if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider answering Yes to Was this reply helpful? or give it a Like ♥
    Visit my blog
    Practical Power Apps    LinkedIn  
  • Travis1238 Profile Picture
    16 on at
    I assume this code goes into the image property of the image in the vertical gallery?   Here is my current code for the image property minus the site name.
     
    "https://XXXXXXXX.sharepoint.com/teams/PlantEngineering/FormPhotos/" & ThisItem.'IMAGE FILE LINK'
     
     
    I'm not familiar with an item's ID.....is this a separate ID for each image?  I've linked the SP doc library to the power app as a data source but I'm not sure how to store or obtain the ID
  • Travis1238 Profile Picture
    16 on at
    OK so I was able to mock this up using the code you provided (Much Thanks!).  I found and added the Item ID column to my sharepoint doc library.  I can see it's just a numerical counter that started at 1 and is increasing by 1 each time a new image is uploaded.   Then I went into my excel file and manually changed the file name to the corresponding numerical Item ID.  After publishing the code I can now see the images on my phone so that's reassuring that I'm on the right path!  
     
    I guess the last hurdle I need to resolve is:  "How can I get the Numerical Item ID created in sharepoint over to my excel file each time the form is submitted"?  The power app is creating the file name and uploading the excel file but it seems I need Item ID instead.  Here is the current code of my submit form along with screen shots of my excel file and my power automate flow.  Any way to return the value from Sharepoint and port it over to the excel file?  Or maybe a better way?
     
     
     
    If(IsBlank(VarCapturedImage), Notify("No photo found. Capture or pick an image before submitting.", NotificationType.Error));
    Set(varFileName, "FormPhoto_" & Text(Now(), "[$-en-US]yyyymmdd_hhmmss") & ".jpg");
    Set(varUploadResult, 'PowerAppV2->Createfile'.Run({ file: { name: varFileName, contentBytes: VarCapturedImage } }));
    Set(varReturnedFileName, varFileName);
    Set(VarCapturedImage, Blank());
    SubmitForm(EditForm3);
    Navigate('Home Screen', ScreenTransition.CoverRight);
     
     
      
     
     
     
     
     
     
     
     
     
     
     
     
  • Verified answer
    WarrenBelz Profile Picture
    153,372 Most Valuable Professional on at
    Firstly, how/when are you creating that Excel record and which fields are unique (identify the particular record).
     
    The next thing I will mention is that Excel is a terrible data source for Power Apps and should be avoided unless you do not have access (which you do) to SharePoint/Dataverse, so I would urge you to change that Excel sheet to a SharePoint List. It also give you a unique identifier for the record (the ID ) which you have noticed is auto generated and cannot be changed. If you must use Excel, I also suggest you get those spaces and special characters out of the file names.
     
    That aside, you get the ID with a Flow action as below (only the last action is different to yours)
     
    and in Power Apps, something like this
    With(
       {
          _ID:
          YourFlowName.Run(
             {
                file:
                {
                   contentBytes: YourImageControl.Image,
                   name: YourFileName
                }
             }
          ).id
       },
       Patch(
          YourExcelTable,
          LookUp(
             YourExcelTable,
             'TASK TITLE' = YourTitle      //example if this is the unique identifier
          ),
          {'IMAGE FILE LINK': Value(_ID)}
       )
    )
     
    The Flow returns the ID of the Library file you have created, which you can then Patch to the relevant record. The other advantage of the ID instead of the file name is that queries using this to the Library are Delegable, whereas using the file name is not (so the Library can be of any size).
     
    Please ✅ Does this answer your question if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider answering Yes to Was this reply helpful? or give it a Like ♥
    Visit my blog
    Practical Power Apps    LinkedIn  
     
     
     
  • Travis1238 Profile Picture
    16 on at
    Much Thanks Warren,
     
    I was able to get this thing working and I really appreciate your support!
     
    I know I need to convert excel to SP or dataverse but my organization has so many rules and blocks that I've had nothing but trouble when I tried to go down that road.  
     
    Thanks again for your help!
     
    Regards,
    Travis

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 431 Most Valuable Professional

#2
MS.Ragavendar Profile Picture

MS.Ragavendar 286 Super User 2025 Season 2

#3
Kalathiya Profile Picture

Kalathiya 258

Last 30 days Overall leaderboard