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

Localization

Uploaded % ( ) Total
Uploaded files: % () Total files:

Uploading file:

Elapsed time:  Estimated time:  Speed:

  • Demo Configurator

RadAsyncUpload provides a mechanism for quick and easy localization, based on the native ASP.NET 2.0 localization. All button labels and messages in the progress area are obtained from the resource files located in the WebSite's App_GlobalResources directory, so that the language of the upload and progress bar can be switched with a single property (Culture).

    <telerik:RadAsyncUpload id="RadAsyncUpload1" runat="server" Culture="en-US" />
    <telerik:RadProgressArea id="RadProgressArea1" runat="server" Culture="en-US" />

Developers can also localize the component for languages, which are not provided with the RadAsyncUpload distribution by modifying the provided resx file.

Additionally, each of the localization strings can be modified at runtime using the Localization property. This saves the need to create a new localization file to change a single string.

Note: Because of the specifics of the Internet forms, chosen files will be uploaded on each postback (e.g. each press of a button).

Note: The largest allowed file size for upload in this example is 50MB. This is specified by the MaxFileSize property set in the RadAsyncUpload declaration. If you attempt to upload a file larger than 50MB the validation will fail and the file won't be uploaded. Also for the purpose of the demo only 6 files are allowed to be uploaded. This is achieved using the MaxFileInputsCount property of the control.

  • DefaultVB.aspx
  • DefaultVB.aspx.vb
  • styles.css
<%@ Page Language="vb" CodeFile="DefaultVB.aspx.vb" AutoEventWireup="false" Inherits="AsyncUpload.Examples.Localization.DefaultVB" %>

<!DOCTYPE html>
<html xmlns='http://www.w3.org/1999/xhtml'>
<head runat="server">
    <title>Telerik ASP.NET Example</title>
    <link rel="stylesheet" type="text/css" href="styles.css" />
</head>

<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
    <telerik:RadSkinManager ID="RadSkinManager1" runat="server" ShowChooser="true" />
    <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server">

        <div class="demo-container size-narrow">

            <telerik:RadAsyncUpload RenderMode="Lightweight" ID="RadAsyncUpload1" runat="server" MaxFileSize="52428800" MaxFileInputsCount="6"  />

            <telerik:RadProgressArea RenderMode="Lightweight" ID="RadprogressArea1" runat="server"  />

        </div>

    </telerik:RadAjaxPanel>

    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="ConfigurationPanel1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="ConfigurationPanel1" LoadingPanelID="RadAjaxLoadingPanel1" />
                    <telerik:AjaxUpdatedControl ControlID="RadAsyncUpload1" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>

    <telerik:RadAjaxLoadingPanel runat="server" ID="RadAjaxLoadingPanel1" />

    <qsf:ConfiguratorPanel runat="server" ID="ConfigurationPanel1">
        <Views>
            <qsf:View Title="Choose language">
                <qsf:ConfiguratorColumn ID="ConfiguratorColumn1" runat="server" Size="Medium">
                    <qsf:RadioButtonList ID="rblLanguages" runat="server" RepeatDirection="Vertical"
                        AutoPostBack="True" Style="margin-left: 1em" OnSelectedIndexChanged="rblLanguages_SelectedIndexChanged">
                        <asp:ListItem Value="en-US" Selected="true"><img src="images/us.gif" alt="English" /> English - United States</asp:ListItem>
                        <asp:ListItem Value="de-DE"><img src="images/german.gif" alt="Deutsch" /> Deutsch - Germany</asp:ListItem>
                        <asp:ListItem Value="fr-FR"><img src="images/french.gif" alt="Francais" /> Francais - France</asp:ListItem>
                    </qsf:RadioButtonList>
                </qsf:ConfiguratorColumn>
            </qsf:View>
        </Views>

    </qsf:ConfiguratorPanel>
    </form>
</body>
</html>

Support & Learning Resources

Find Assistance