Gets or sets the allowed file extensions for uploading.
Namespace: Telerik.WebControls
Assembly: RadUpload (in RadUpload.dll)
Syntax
| Visual Basic (Declaration) | |
|---|
Public Property AllowedFileExtensions As String() |
| Visual Basic (Usage) | Copy Code |
|---|
Dim instance As RadUpload
Dim value() As String
instance.AllowedFileExtensions = value
value = instance.AllowedFileExtensions
|
| C# | |
|---|
public string[] AllowedFileExtensions {get; set;} |
Return Value
The default value is empty string array. In order to check for multiple file
extensions you should set an array of strings containing the allowed file extensions
for uploading.
Example
This example demonstrates how to set multiple allowed file extensions in a
RadUpload control.
| Visual Basic | Copy Code |
|---|
Dim allowedFileExtensions As String() = New String(2) {".zip", ".doc", ".config"}
RadUpload1.AllowedFileExtensions = allowedFileExtensions |
| C# | Copy Code |
|---|
string[] allowedFileExtensions = new
string[3] {".zip", ".doc", ".config"};
RadUpload1.AllowedFileExtensions = allowedFileExtensions;
|
Remarks
Requirements
Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family
See Also