New to Telerik UI for ASP.NET AJAXStart a free 30-day trial

Binding RadLightBox to BinaryImage

The example below demonstrates how the RadLightBox control can be bound to a BinaryImage:

ASP.NET
<telerik:RadScriptManager ID="RadScriptManager1" runat="server">
      <Scripts>
          <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />
          <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" />
          <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js" />
      </Scripts>
  </telerik:RadScriptManager>
  <telerik:RadCodeBlock runat="server">
      <script type="text/javascript">
          function OpenLigthBox() {
              var lightBox = $find('<%= RadLightBox1.ClientID %>');
          lightBox.show();
      }
      </script>
  </telerik:RadCodeBlock>
  <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" EnableAJAX="false">
      <AjaxSettings>
          <telerik:AjaxSetting AjaxControlID="RadLightBox1">
              <UpdatedControls>
                  <telerik:AjaxUpdatedControl ControlID="RadLightBox1" />
              </UpdatedControls>
          </telerik:AjaxSetting>
      </AjaxSettings>
  </telerik:RadAjaxManager>
  <asp:Button Text="Open LightBox" OnClientClick="OpenLigthBox(); return false;" runat="server" />
  <telerik:RadLightBox RenderMode="Lightweight" ID="RadLightBox1" runat="server" PreserveCurrentItemTemplates="true">
      <ClientSettings AllowKeyboardNavigation="true"></ClientSettings>
  </telerik:RadLightBox>

Not finding the help you need?
Contact Support