logo
search
Others

Fix Power Apps Camera Collection Not Clearing with a Timer

Maira MehtabMaira Mehtab Sep 24, 2026 869 views

Question details

The user is running a parcel-scanning application in Power Apps that captures barcode photos to add as SharePoint attachments, but the timer fails to clear the collection for new images.

Product
Microsoft Power Apps
Device & OS
not provided
Scenario
Automating barcode photo capture using a timer control and submitting those photos as attachments to a SharePoint list.
Observed behavior
During timer-triggered runs, the application reuses the first captured photo instead of clearing the image collection and capturing a new photo.
Before you start

Before making changes to your formulas, ensure you have saved and published a backup version of your Power App, and verify that your Timer control's Repeat and AutoStart properties are configured correctly.

Solution 1Recommended

Implement ClearCollect and Reset Logic in the Timer Control

Force the application to clear the existing image collection and refresh the camera control whenever the timer completes its cycle.

If a collection is not explicitly cleared, Power Apps will simply append new images or, depending on the formula, fail to register a new capture. Using the correct reset sequence ensures a fresh state for each scan.

1
Select the Timer Control

Open your app in Power Apps Studio, select the Timer control responsible for triggering the photo capture, and go to the 'OnTimerEnd' property in the formula bar.

2
Clear the existing collection

Add the 'Clear(YourCollectionName)' or use 'ClearCollect(YourCollectionName, Camera1.Photo)' to ensure any previously stored barcode image is removed before the new one is processed.

3
Reset the Camera Control

Add the 'Reset(Camera1)' function directly after your collection logic. This forces the camera feed to refresh, preventing it from freezing on the first captured frame.

Variable State: If you are using Context Variables (UpdateContext) to store the image instead of a collection, ensure you are setting the variable to Blank() before assigning the new camera photo.
Free Microsoft Office alternative

Looking for a Lightweight Office Suite Alternative?

While Microsoft Power Apps is great for custom business logic, standard document, spreadsheet, and presentation tasks don't require complex platforms. WPS Office provides a streamlined, highly compatible, and free alternative to Microsoft Office for your daily productivity needs.

  1. 1. Download the Installer: Visit the official WPS Office website and download the free installation package for your operating system.
  2. 2. Install and Launch: Follow the on-screen instructions to install the suite, which integrates Writer, Spreadsheets, and Presentation into one window.
  3. 3. Open Your Files: Drag and drop your existing Microsoft Office files into WPS Office to continue working seamlessly with original formatting intact.
Fully compatible with Microsoft Word, Excel, and PowerPoint file formats (.docx, .xlsx, .pptx).Lightweight application that uses minimal system resources and launches instantly.Familiar tabbed user interface, ensuring zero learning curve for migrating users.Includes a powerful built-in PDF toolkit for editing, converting, and signing documents.
microsoft office alternative - wps office

Frequently Asked Questions

Why does my Power Apps camera control freeze on the first picture?

This commonly occurs if the camera control is not commanded to reset between captures. Adding the Reset(CameraName) function to your capture button or timer trigger forces the hardware feed to refresh.

What is the difference between Collect and ClearCollect in Power Apps?

The Collect function appends new items to the bottom of an existing collection. In contrast, ClearCollect deletes all existing records in the collection first, ensuring only the newly added item remains.

How do I correctly attach photos to SharePoint from Power Apps?

Photos captured via the camera control must be collected, formatted correctly (often requiring JSON or Base64 conversion depending on the method), and submitted using the Patch function mapped to the SharePoint list's Attachments column.