How to hide/remove the upload/delete button in

1 Answer 119 Views
Button Upload
Tayger
Top achievements
Rank 1
Iron
Tayger asked on 30 Sep 2024, 08:59 AM

After selecting a file in kendoUpload two buttons show up: Upload and Clear:

Is it possible to hide those two buttons? I want to do the upload process programmatically.

I already found out that the two buttons are not accessible after initialization of the kendoUpload widget but also not right away after the SELECT event triggers (on selecting a file to be uploaded). I have found a solution waiting some milliseconds in the SELECT event to hide the two buttons:

setTimeout(function() {
$('k-actions').css('display', 'none');
}, 10);

Is there a more proper way to hide those buttons?

I'm working with KendoUI for JQuery, very latest official version.

Regards

 

 

1 Answer, 1 is accepted

Sort by
0
Martin
Telerik team
answered on 02 Oct 2024, 12:52 PM

Hello, Farai,

The approach you are using is the only one at this point to hide the buttons. The Upload doesn't expose an option to remove them when autoUpload is set to false.

Let me know if you have any further questions.

Regards,
Martin
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Tayger
Top achievements
Rank 1
Iron
commented on 02 Oct 2024, 01:28 PM

Ok, thank your for confirmation. Maybe the can once be configured in future via the options. The programmatical upload makes sense if you want to send data along with the uploaded files while the data are like the key entry and the file to be uploaded is related to it.
Martin
Telerik team
commented on 07 Oct 2024, 06:40 AM

Hello, Farai,

If you need to send additional data when uploading a file, please take a look at this How-To article. Let me know if that would be useful.

Tags
Button Upload
Asked by
Tayger
Top achievements
Rank 1
Iron
Answers by
Martin
Telerik team
Share this question
or