Leadtools.Web.Controls Namespace > WebThumbnailViewer Class : GetThumbnailInfo Method |
public ThumbnailInfo GetThumbnailInfo( int thumbIndex )
'Declaration Public Function GetThumbnailInfo( _ ByVal thumbIndex As Integer _ ) As ThumbnailInfo
'Usage Dim instance As WebThumbnailViewer Dim thumbIndex As Integer Dim value As ThumbnailInfo value = instance.GetThumbnailInfo(thumbIndex)
public ThumbnailInfo GetThumbnailInfo( int thumbIndex )
function Leadtools.Web.Controls.WebThumbnailViewer.GetThumbnailInfo( thumbIndex )
public: ThumbnailInfo GetThumbnailInfo( int thumbIndex )
Public Function WebImageViewer_GetThumbnailImage(ByVal webThumbnailViewer As WebThumbnailViewer) As RasterImage Dim image As RasterImage = Nothing If (webThumbnailViewer.Count > 1) Then Dim thumbInfo As ThumbnailInfo = webThumbnailViewer.GetThumbnailInfo(0) Dim thumbImageUrl As String = thumbInfo.Url If (Not thumbInfo.CacheFileName = String.Empty) Then thumbImageUrl = thumbInfo.CacheFileName End If Dim codecs As RasterCodecs = New RasterCodecs() Dim filePath As String = webThumbnailViewer.Page.MapPath(thumbImageUrl) image = codecs.Load(filePath, 0, CodecsLoadByteOrder.BgrOrGray, thumbInfo.Page, thumbInfo.Page) End If Return image End Function
public RasterImage WebThumbnailViewer_GetThumbnailImage(WebThumbnailViewer webThumbnailViewer) { RasterImage image = null; if(webThumbnailViewer.Count > 1) { ThumbnailInfo thumbInfo = webThumbnailViewer.GetThumbnailInfo(0); string thumbImageUrl = thumbInfo.Url; if(thumbInfo.CacheFileName != string.Empty) thumbImageUrl = thumbInfo.CacheFileName; RasterCodecs codecs = new RasterCodecs(); string filePath = webThumbnailViewer.Page.MapPath(thumbImageUrl); image = codecs.Load(filePath, 0, CodecsLoadByteOrder.BgrOrGray, thumbInfo.Page, thumbInfo.Page); } return image; }
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2