New to Telerik UI for ASP.NET MVC? Download free 30-day trial

UploadFileBuilder

Methods

Name(System.String)

Specifies the name of the file

Parameters

name - System.String

The file name

Example


            @( Html.Kendo().Upload()
                .Name("files")
                .Files(files => files.Add().Name("file.txt").Size(500).Extension(".txt"))
                .Async(a => a
                    .Save("Save", "Compose")
                    .Remove("Remove", "Compose")
                )
            )

Size(System.Int64)

Specifies the size of the file in bytes

Parameters

size - System.Int64

The file size

Example


            @( Html.Kendo().Upload()
                .Name("files")
                .Files(files => files.Add().Name("file.txt").Size(500).Extension(".txt"))
                .Async(a => a
                    .Save("Save", "Compose")
                    .Remove("Remove", "Compose")
                )
            )

Extension(System.String)

Specifies the extension of the file

Parameters

extension - System.String

The file extension

Example


            @( Html.Kendo().Upload()
                .Name("files")
                .Files(files => files.Add().Name("file.txt").Size(500).Extension(".txt"))
                .Async(a => a
                    .Save("Save", "Compose")
                    .Remove("Remove", "Compose")
                )
            )

In this article
Not finding the help you need?