8 votes
Accepted

using Lightning:fileUpload to attach files to a record that isn't created yet

As an alternative, I considered assigning the current User Id to the File Uploader, so all attachments will be linked to the user, and then I could run some code in my save() method later to re-assign ...
Charles T's user avatar
  • 11k
8 votes
Accepted

Error: Received exception event aura:systemError from server

The maximum payload for Aura/LWC is 4 MB. Files are uploaded in Base-64 encoded format, which limits the file to about 3 MB in total (minus protocol overhead for calling a server method). Depending on ...
sfdcfox's user avatar
  • 487k
7 votes

How to upload larger size file using input tag of type html in LWC

You'll need to implement workarounds as of now if you need custom functionality w.r.t uploading files. The max content limit for AuraEnabled methods as mentioned by Pranay Jaiswal is 4MB, which is ...
Prashant Kashyap's user avatar
7 votes
Accepted

Uploading Multiple file using fileReader in lwc

Reading a file is asynchronous. This means that the upload code will happen before the files are read, and there won't be any files to read, so nothing happens. Instead, you need to wait for the files....
sfdcfox's user avatar
  • 487k
5 votes
Accepted

Lightning File Upload Component - Event Not Firing

Been searching for the answer and think I may have found it! Apparently, the event will not fire in standalone apps or lightning out. To test I put the same component on a record page and, behold, it ...
Jake Hebert's user avatar
5 votes

Is it possible to upload files as a guest user in a community?

I did a quick test and it is indeed possible to upload a file using guest user in a community. Below are further details on your specific questions. Is it possible to upload files as a guest user ...
Jayant Das's user avatar
  • 30.4k
5 votes
Accepted

lightning:fileUpload is coming as disabled

From documentation: File uploads are always associated to a record, hence the recordId attribute is required. As for: I have also checked in a stand alone app The reason is because it's not ...
Jayant Das's user avatar
  • 30.4k
5 votes

Is there any difference between the heap consumption in sandbox and production orgs?

The amount of heap used is the same in all types of orgs; one byte of data is still one byte of data. Once you go over 6MB in a single transaction, Salesforce may choose to terminate the process (or ...
sfdcfox's user avatar
  • 487k
5 votes
Accepted

LWC: Standard file upload does not update field in file-field-name attribute

The API name of the custom field must end with fileupload__c. Please refer to documentation https://developer.salesforce.com/docs/component-library/bundle/lightning-file-upload/documentation
Digvijay Singh's user avatar
4 votes
Accepted

Where is a File's "Customer Access" status located?

It's on the ContentDocumentLink under Visibility as shown here Visibility can have the following values. AllUsers—The file is available to all users who have permission to see the file. ...
Kris Goncalves's user avatar
4 votes
Accepted

LWC: Maximum Blob Size From JS To APEX

What would be the maximum size of a blob that I can pass from the JS side to APEX. It was documented to be 1 mb from lightning component to Apex in 1 transaction. However I do not find that ...
salesforce-sas's user avatar
4 votes

Can you use lightning-file-upload without saving?

There's a third option. You can use lightning:input type="file" option if you want the look and feel without saving the file to Salesforce.
sfdcfox's user avatar
  • 487k
4 votes
Accepted

How to change default file upload size limit in salesforce?

These Permissions can be only changed by Salesforce Support Team. You need to open a Case to salesforce support team and give the details so they will validate and change it.
SaiPraveen Kakkirala's user avatar
3 votes
Accepted

Winter 20 breaks communities guest file upload

Partner support have replied to me and provided a working solution! Follow this tutorial https://developer.salesforce.com/blogs/developer-relations/2017/05/build-lightning-file-uploader-component....
J Dubbs's user avatar
  • 392
3 votes

Trigger on content document to retrieve the body

ContentVersion works very different from Attachment Object. When you have a trigger on it for before insert, You will get these value in trigger.new:- ContentVersion:{Id=null, ContentDocumentId=...
sanket kumar's user avatar
  • 15.2k
3 votes
Accepted

Lightning File upload to refresh a child component after file upload

From your parent component, you can use aura:method to call child component method. Define this in child component <aura:method name="sampleMethod" action="{!c.doInit}" description="Calling chld ...
Tushar Sharma's user avatar
3 votes
Accepted

How to fire a process builder after a document is added to an oppty/object

Unfortunately, process builder on content objects is not supported. You can vote the idea here and maybe it can make it to the roadmap. Alternatively, you can write a trigger on the Content object ...
manjit5190's user avatar
  • 7,983
3 votes

Guest users are unable to upload a file in a community

Do you have the "Allow site guest users to upload files" checkbox checked? If not, you can go to Quick Find > General Settings > Allow site guest users to upload files (check it). You ...
Samuel Castillo's user avatar
3 votes
Accepted

File Upload Making as Public - Image is not Showing in HTML img tag

Instead of DistributionPublicUrl Use ContentDownloadUrl SELECT ContentDownloadUrl FROM ContentDistribution WHERE ContentDocumentId You must get the ContentDownloadURL in the Image Source of the Site ...
user3214361's user avatar
3 votes
Accepted

How to get the uploaded file's size when using lightning-file-upload?

There is no way from lightning-file-upload itself. This is all from the lightning-file-upload docs. One reason it doesn't provide the size is that it handles the file size limit automatically (and ...
Kris Goncalves's user avatar
3 votes
Accepted

Experience Site: Lightning-file-upload Issue

As of today (Spring 22), lightning-file-upload is not supported in the Lightning Web Runtime digital experience https://developer.salesforce.com/docs/atlas.en-us.232.0.exp_cloud_lwr.meta/exp_cloud_lwr/...
Jeff Kranz's user avatar
  • 1,947
2 votes

Correct approach uploading File using REST API (file size 100 MB)

You'll want to read Inputs and Binary File Uploads, but basically, you can't use base-64-encoded data, as far as I can tell. You could try setting Content-Transfer-Encoding to BASE64, but I'm not sure ...
sfdcfox's user avatar
  • 487k
2 votes
Accepted

Can you upload a file from a Cloudpage into a Marketing Cloud FTP

I assume you are wanting to have a CloudPage form where a customer can fill in their details and then attach a file - which you then want the file to upload to the FTP server ? Ampscript and SSJS do ...
Gravitai's user avatar
  • 2,850
2 votes

Can you upload a file from a Cloudpage into a Marketing Cloud FTP

You can do this but not directly. You would have to run a data extract on the data extension the form goes to and transfer it into the ftp. You can put these two into an automation in automation ...
0xsegfault's user avatar
  • 6,583
2 votes

How to read file(pdf or excel or outlook msg) from the path given in CSV and upload that file in Attachment object?

Apex Code can't read or write files directly to your computer. There's too many layers of security and other limitations that prevent this from happening. Literally, what you're doing in your code is ...
sfdcfox's user avatar
  • 487k
2 votes
Accepted

How to upload a New Version of an existing File using lightning:fileUpload lightning base component?

This cannot be done with the lightning:fileUpload component. I solved this problem with the lightning:openFiles event. This way a user has a preview of the file and inside the previewer you can ...
Itai Shmida's user avatar
  • 5,015
2 votes
Accepted

How to identify which lightning:fileUpload was clicked

instead of using aura:id or Id you can use name attribute of fileUploadComponent <aura:component> <aura:attribute name="files" type="FileWrapper[]" /> <aura:iteration items="{!...
Pranay Jaiswal's user avatar
2 votes
Accepted

lightning:fileUpload displayed as disabled in community

You need to forcibly add the component to an Object record page, otherwise the ID will not bind to your component attribute, I had the same behavior a while back when implementing it. Note, the ...
glls's user avatar
  • 20.1k
2 votes

using Lightning:fileUpload to attach files to a record that isn't created yet

In one of the orgs I have worked in we wanted to be able to do something similar. What we ended up doing was creating an additional submit button called 'submit and upload files'. When the user ...
Brian Simpson's user avatar
2 votes
Accepted

Use visualforce page from Buttons, Links, and Actions in custom lightning component in case of S3 Amazon Uploader

The way you can achieve it would be hosting your vfpage in a lightning component using an Iframe and use postMessage() function to send parameters from lightning component to vfpage. Your lightning ...
Hemavantha Rajesh Varma Mudunu's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible