Compare File Size During Upload

I'm looking for a recommendation/guidance on how to compare the file size of what's being loaded and a preexisting file on an s3 bucket?

Thanks

High level...

Turn on the "output" for all the file related components you try in your server connect API script so you can see what properties are returned. Then monitor your webserver logs to see the output.

S3: you'll need to know the existing file in S3 and read its properties. Wappler has a 'get file' for S3, then look into the other file components in Wappler to get its properties. May need some formatting to single out the file size. Save size as a variable.

Upload: you'll also need to know the path and file name uploaded to your server. The File Upload component gives you control over location and file name. Again, look into Wappler's file components to discover which one will output file size. Save size as a variable.

Use a condition to compare the file sizes.