Explorer preview

  • Thread starter Thread starter Bernhard
  • Start date Start date
B

Bernhard

Hi,

in Windows Explorer it is possible to display a small preview e.g. of
images, a Word document or an HTML page. How can this preview be added to a
..Net WindowsForm?

Thanks :-)
Bernhard
 
I think you are talking about thumbnails. If so, you can do it like this:

Dim image = New Bitmap("My Image With Extension")
Dim pThumbnail As Image = image.GetThumbnailImage(100, 100, Nothing,
New IntPtr)
e.Graphics.DrawImage( pThumbnail, 10, 10, pThumbnail.Width,
pThumbnail.Height)

The above will create a thumbnail 100 * 100.

I hope this helps.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top