LightBox - Localization

Climbing Thumbnail Diving Thumbnail Football Thumbnail Hang Glider Thumbnail Mountain Biking Thumbnail Skiing Thumbnail Snowboarding Thumbnail Surfing Thumbnail Swimming Thumbnail Yoga Thumbnail

Demo Configurator

Choose language

Isolate this demo as a stand-alone application
  • About this demo
  • C#
  • VB

This demo shows how to localize RadLightBox with minimum efforts using global resource files. You just need to copy the *.resx files (including the RadLightBox.Main.resx file) to the App_GlobalResouces folder, set the Culture property and you are ready to go.

  • DefaultCS.aspx
  • DefaultCS.aspx.cs
  • styles.css
<%@ Page Language="C#" Inherits="Telerik.GridExamplesCSharp.AccessibilityAndInternationalization.Localization.DefaultCS"CodeFile="DefaultCS.aspx.cs"  %>

<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns='http://www.w3.org/1999/xhtml'>
<head runat="server">
    <title>Telerik ASP.NET Example</title>
    <link href="styles.css" rel="stylesheet" />
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
    <telerik:RadSkinManager ID="RadSkinManager1" runat="server" ShowChooser="true" />
    <div class="demo-container">
        <div class="row">
            <asp:Image ID="Image1" AlternateText="Climbing Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Climbing_thumbnail.jpg" />
            <asp:Image ID="Image2" AlternateText="Diving Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Diving_thumbnail.jpg" />
            <asp:Image ID="Image3" AlternateText="Football Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Football_thumbnail.jpg" />
            <asp:Image ID="Image4" AlternateText="Hang Glider Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Hang_glider_thumbnail.jpg" />
            <asp:Image ID="Image5" AlternateText="Mountain Biking Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Mountain_Biking_thumbnail.jpg" />
            <asp:Image ID="Image6" AlternateText="Skiing Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Skiing_thumbnail.jpg" />
            <asp:Image ID="Image7" AlternateText="Snowboarding Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Snowboarding_thumbnail.jpg" />
            <asp:Image ID="Image8" AlternateText="Surfing Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Surfing_thumbnail.jpg" />
            <asp:Image ID="Image9" AlternateText="Swimming Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Swimming_thumbnail.jpg" />
            <asp:Image ID="Image10" AlternateText="Yoga Thumbnail" runat="server" CssClass="gray" ImageUrl="images/ThumbnailImages/Yoga_thumbnail.jpg" />
        </div>
        <telerik:RadLightBox RenderMode="Lightweight" ID="RadLightBox1" runat="server" Modal="true" LoopItems="true" ZIndex="100000">
            <ClientSettings AllowKeyboardNavigation="true" NavigationMode="Zone" FullscreenMode="Native">
            </ClientSettings>
            <Items>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Climbing.jpg" Title="Climbing" TargetControlID="Image1">
                </telerik:RadLightBoxItem>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Diving.jpg" Title="Diving" TargetControlID="Image2">
                </telerik:RadLightBoxItem>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Football.jpg" Title="Football" TargetControlID="Image3">
                </telerik:RadLightBoxItem>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Hang_glider.jpg" Title="Hang glider" TargetControlID="Image4">
                </telerik:RadLightBoxItem>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Mountain_Biking.jpg" Title="Mountain Biking" TargetControlID="Image5">
                </telerik:RadLightBoxItem>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Skiing.jpg" Title="Skiing" TargetControlID="Image6">
                </telerik:RadLightBoxItem>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Snowboarding.jpg" Title="Snowboarding" TargetControlID="Image7">
                </telerik:RadLightBoxItem>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Surfing.jpg" Title="Surfing" TargetControlID="Image8">
                </telerik:RadLightBoxItem>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Swimming.jpg" Title="Swimming" TargetControlID="Image9">
                </telerik:RadLightBoxItem>
                <telerik:RadLightBoxItem ImageUrl="images/OriginalImages/Yoga.jpg" Title="Yoga" TargetControlID="Image10">
                </telerik:RadLightBoxItem>
            </Items>
        </telerik:RadLightBox>
    </div>
    <qsf:ConfiguratorPanel runat="server" ID="ConfigurationPanel1">
        <Views>
            <qsf:View>
                <qsf:ConfiguratorColumn ID="ConfiguratorColumn1" runat="server" Size="Narrow" Title="Choose language">
                    <qsf:RadioButtonList ID="radiobuttonlistLanguages" runat="server" RepeatDirection="Vertical"
                        AutoPostBack="True" Style="margin-left: 1em" OnSelectedIndexChanged="radiobuttonlistLanguages_SelectedIndexChanged">
                        <asp:ListItem Value="de-DE"><img src="flags/german.gif" alt="Deutsch"/> Deutsch</asp:ListItem>
                        <asp:ListItem Value="en-US" Selected="true"><img src="flags/english.gif" alt="English" /> English</asp:ListItem>
                        <asp:ListItem Value="fr-FR"><img src="flags/french.gif" alt="Français" /> Français</asp:ListItem>
                    </qsf:RadioButtonList>
                </qsf:ConfiguratorColumn>
            </qsf:View>
        </Views>
    </qsf:ConfiguratorPanel>
    </form>
</body>
</html>

Support & Learning Resources

Find Assistance

Help Us Improve

Was this example helpful?