Issue
I'm using Angular 13 with PrimeNG 13. I want to allow a file upload in my form so I have created
<p-fileUpload [maxFileSize]="1000000" [customUpload]="true" [multiple]="false" formControlName="myFile"></p-fileUpload>
This creates a single file dialog with "Choose", "Upload" and "Cancel" buttons. It seems that after choosing a file, I must then click "Upload" to get the file into my form.
Is there a way to create the component so that it only allows for upload of a single file and that initially choosing the file adds it into my form?
Solution
According to documentation you should add below properties:
mode="basic"
[auto]="true"
Answered By - Fseee
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.