How to reduce image file before uploading?

1. //Android//

Hello everybody, I need to upload a file (taken by my camera) but the limit is about 1Mo.

I would like to reduce it before to send it but I don’t have an idea how to perform this action.

Here is my code :

button_take_photo.setOnClickListener(new View.OnClickListener() {

        @Override         public void onClick(View v) {             Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);             File photoFile = null;             try {                 photoFile = createImageFile();             } catch (IOException e) {                 e.printStackTrace();             }             // Continue only if the File was successfully created             if (photoFile != null) {                 Uri photoURI = getUriForFile(                         context,                         "",                         photoFile);                 intent.putExtra(MediaStore.EXTRA_OUTPUT, photoURI);                 startActivityForResult(intent, REQUEST_TAKE_PHOTO);             }         }     }); } 

private File createImageFile() throws IOException {

    // Create an image file name     String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss").format(new Date());     String imageFileName = "JPEG_" + timeStamp + "_";     File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);     File image = File.createTempFile(             imageFileName,  /* prefix */             ".jpg",         /* suffix */             storageDir      /* directory */     );      // Save a file: path for use with ACTION_VIEW intents     currentPhotoPath = image.getAbsolutePath();     return image; 

Here I try to upload the file

protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {

    if (requestCode != RESULT_CANCELED) {            // Intent intent = new Intent(this, UploadPhoto.class);         if (id2 != null) {            // intent.putExtra("ID", id2);             File imageFile = new File(currentPhotoPath);             uploadImage(imageFile,id2);         } else {             //intent.putExtra("ID", myDatabaseHelper.getMuseeIdByName(nameMusee));             File imageFile = new File(currentPhotoPath);             uploadImage(imageFile, myDatabaseHelper.getMuseeIdByName(nameMusee));         }     } } 

Thank you in advance

Issues Uploading Ad on DigitalPoint

I am trying to upload a new banner for my ads, but every time I click the upload button and select my file, it refreshes the page and the ad does not upload.

I have already emailed support 2 days ago and have heard nothing but my ads are continuing to spend. How can I fix this?

Is anyone else having these issues?


Authentication error while uploading file or sending email aws

By mistakenly I deleted all the IAM users from aws. And Now when I tried to upload the file into aws via node.js code, I am getting the error:

The AWS Access Key Id you provided does not exist in our records.

and when I trying to send the email from node.js code with ses credentials, I am getting the error:

Invalid login: 535 Authentication Credentials Invalid.

However, I created new access key and secret key pair to solve this problem, But still same issue. Can anyone please help with the same?

Instagram profile photo uploading sideways

I’ve encountered this instagram bug/glitch and it’s been really bothering me for a while now. 

Every time I try and upload a new profile picture, right after the crop section, my photo somehow automatically gets rotated clockwise and that ends up being the photo that gets uploaded as my profile picture. 

I tried uninstalling and reinstalling the app, cleared cache, cleared storage, force stopped. But nothing worked 

Do note that this happens only for photos were I am present.  Other photos go unaffected. 

Can someone please help me? I use a OnePlus6 btw

Uploading a file to Sharepoint on iPad modifies filename

I am using an iPad to upload files to a Sharepoint library from onedrive The SPO library is using modern experience

The added file names are changed after upload A guid is prepended to the file name Eg file to upload – testc3.docx Filename modified to 817BFD26-C1E2-4384-9663-1D9C59EC9C4Etestc3.docx

Anybody any ideas how I can prevent this from happening? Everything works fine on PC

view after uploading files on ipad

File uploading issue

We’re having issues uploading files. Some files encounter an error message that states “The specified file temporary://p1dah901n910tl8lv14.tmp could not be copied, because no file by that name exists. Please check that you supplied the correct filename.” That temporary file name is different each time. The original filename, format, and size don’t seem to have any influence on what files get rejected. Any idea what could be causing this? This happens when uploading with IMCE as well as via the Content > Files page. Running Drupal 7.

Uploading files to SharePoint Library and referencing excel file to fill in column values

I am brand spanking new to SharePoint. I have been tasked with developing a SharePoint site that will facilitate finding documents, and better organize them than they currently are on our network drives. I am now trying to set up a specifications library.

there are:

  • Specifications
  • Standard Specifications Exceptions
  • Non Standard Specification Exceptions

The non standard specification exceptions are also broken into 4 regions where the same exemption file name can have different contents.

Originally I was planning on uploading everything into one Library and using different views to see the information. But after reading another question on here, it sounds like a separate library for each is the better approach.

In the end I will have probably about 3K +/- documents to upload. They will be a mix of PDF, XML, DOC, and DWG. Every file will have a unique name. Some of the file formats will be:

NSP BIRD.XML NSP 001A820.XML NSP 100F08M.xml OPSS 0202.pdf OPSS 0304.pdf SSP 101F23.xml SSP 102S05.xml MTOD 0101.0700.dwg MTOD 0202.0400.dwg OPSD 0100.0100.dwg OPSD 0100.0110.dwg SSD 0002.0001.dwg SSD 0005.0002.dwg 

Currently each of the type defined by the first 3-4 characters is in its own directory. Also each directory has an excel file which holds an index. Which are all similar, but column names, count and position may vary slightly from one index to the next.

An example index would look like:

enter image description here

Based on this table I know that SSD 0002.0001.dwg has the title:

Structural Standard Drawings Layering Structure 

And that its Status is:


While I can drag an drop 100 files at a time and manually go into the library an and fill in the column information for each file it is rather time consuming.

Is there a way for the files to be uploaded and have the appropriate column information pulled from the index file?

As a followup question is there a better way of doing this? Previously I just made a hyperlink formula in each index that linked to the file on the network drive.

No clue what to tag this as either so some assistance with that would be appreciated.