Tales from the Evil Empire

Bertrand Le Roy's blog

News

Ads Via DevMavens

ASP.NET AJAX UpdatePanel Control: Add Ajax interactivity to your ASP.NET 2.0 web pages

Add to Technorati Favorites

Blogs I read

My other stuff

A simple ASP.NET photo album

In June, Dmitry posted a very simple photo album on his blog. I immediately liked it because it's both easy to set-up (just drop the ashx file into your web site's photo directory) and to manage (no need to upload images one by one using a clumsy web upload field, just upload new photos using ftp or the file system). It's also nice to browse. Sure, there are no fancy ratings or comments features, you can't add titles or descriptions, but frankly, I didn't need all these features.

Still, I wanted to change a few things so I went ahead and added the following to Dmitry's handler:

  • XHTML output
  • CSS styling
  • EXIF meta-data reading and displaying
  • Sorting by date shot
  • Stacked photos folder icons (uses default.jpg if it exists)
  • Folder names respect casing and special characters
  • In-handler pseudo-config (just modify the handler's configuration block with any text editor)
  • Thumbnail caching on disk or in memory
The thumbnail caching on disk is an essential improvement because if you have a large number of heavy pictures, memory won't be the right place to cache. If the handler is configured to save on disk (which is the default), the thumbnails are stored in the application's temporary folder, the very same place where pages are compiled. This means that you don't need to set writing permissions, but it also means that you need to run in high or full trust. If you can't do that, you should configure the handler to cache in memory or not at all.

Photo album folders
Viewing folders

Photo Album List View
Viewing thumbnails

Photo Album Details View
Viewing details

The handler is under a shared source licence, which means that you can do pretty much what you want with it. It uses the Metadata public domain library by Drew Noakes and adapted for .NET by Renaud Ferret to extract the EXIF information from the jpeg files. This library can be downloaded from http://renaud91.free.fr/MetaDataExtractor. Please use the dll from the workspace below, though, as I've made a small correction. I've also sent the correction to Renaud, but he may not publish a new version immediately...

Download the code for the handler here:
http://www.codeplex.com/PhotoHandler

Special thanks should go to Dmitry Robsman and David Ebbo.

UPDATE: the handler is now hosted on Codeplex.

Comments

Martin Dolphin said:

Hi

Tried this and it's very nice indeed - thanks for your efforts. Is the version on gotdotnet the same as your demo pics? When I tried it the output doesn't look as neat and the pictures all appear in a single column.
# September 9, 2005 3:54 AM

Mischa Kroon said:

Wow looks very nice... I will definately be testing this out for a image gallery part of a personal website :)
# September 9, 2005 4:23 AM

Bertrand Le Roy said:

You're absolutely right, the CSS that's included in release 1.1 is an old version. You can now download the right CSS file from release 1.1.1 or from source control.
Please tell me how that works for you.
# September 9, 2005 1:27 PM

Mischa Kroon said:

Stupid question but how do I get this to work.

Just putting it in the right directory didn't do much for me.
# September 12, 2005 2:51 AM

Bertrand Le Roy said:

Mischa, what happens when you browse to the handler?
# September 12, 2005 1:35 PM

neks said:

this is great
# June 1, 2006 9:04 PM

Rio said:

Can u tell me how implement this.
I mean that how to create simple album application.
Pls
# June 27, 2006 4:11 AM

Bertrand Le Roy said:

Rio, why don't you start by downloading the source code and studying it?
# June 27, 2006 4:19 AM

Infinity said:

possible to support bmp, gif and png also ?
# September 20, 2006 3:01 AM

Bertrand Le Roy said:

Infinity: it's shared source, so feel free to implement that, but I won't in the near future, jpeg being the dominant format for photos. Sorry.

# September 20, 2006 7:53 PM

Tom said:

This is a great software.

But I can only run it on Windows 2000 Server. I've tried two different Windows 2003 servers. With no luck.

Does anybody know how to get this running on Windows 2003 Server?

# December 31, 2006 4:52 AM

Bertrand Le Roy said:

Tom, I'm running it at home on Windows 2003 Server without a problem. What exactly is the problem you're seeing? Are you sure you have ASP.NET 2.0 installed? Is ASP.NET activated in IIS?

# December 31, 2006 3:15 PM

Lloyd said:

I dropped the files in an image directory, and I'm getting the following error: "The type or namespace name 'com' could not be found" on the com.drew.metadata namespaces.

# January 2, 2007 2:03 AM

Bertrand Le Roy said:

For the moment, you also need to copy the dll to the bin folder. I'm working on a new version that removes that requirement.

# January 2, 2007 2:08 AM

Lloyd said:

Thanks for the quick response.  To clarify, I moved MetaDataExtractor.dll to my site's root bin directory, and that solved the problem.  Looks like a great tool.

# January 2, 2007 2:15 AM

Jared said:

Looks good, but the link to download isn't working.  This is a long shot, but would you want to code in a user management system so only certain users could access certain folders?

# January 24, 2007 6:26 PM

Bertrand Le Roy said:

Jared: I just tried the link and it's working for me. Maybe the site was down when you tried. I don't think there's a need for a specific user management system: the built-in membership system of ASP.NET should work fine with it.

# January 24, 2007 10:31 PM

Jared said:

Looks like the link was down when I last tried, thanks.  I've been playing around with it a bit (mainly to get it to play with a different source directory, a networked drive) and noticed it has trouble with hidden/corrupted .jpg files (these are being created by Mac users somehow).  Also, is there any way to add in non-jpeg files (gif, tif, png, etc.)?  It seems it is limited to what the MetaDataExtractor can read.

# January 29, 2007 2:32 PM

Bertrand Le Roy said:

Jared: I think you'd have to fix those jpgs before you use them with the handler. Both corrupt jpg and non-jpg file handling are features I don't plan on adding for the moment as I have little time and more important features to implement but feel free to modify the code any way you want and implement those.

# January 29, 2007 2:55 PM

Vincent said:

Bertrand: i downloaded the albumhandler.zip (2.0 and 2.1) and extract the files into the image folder... when i run it, i got the following message:  

Parser Error Message: Type 'AlbumHandler' does not inherit from 'System.Web.UI.UserControl'.

Source Error:

Line 2:  <%@ Register Src="~/album.ashx" TagPrefix="photo" TagName="album" %>

Do you have any idea what causes the problem?

# February 13, 2007 11:32 PM

Bertrand Le Roy said:

You probably don't have ASP.NET 2.0 installed, or it's not active on that application.

# February 14, 2007 1:29 PM

Mike said:

Hey it's really great!!

Is it possible to scan only a certain folder? Because right now it scans everything in my website ehhe

# April 12, 2007 3:38 PM

Bertrand Le Roy said:

Mike: just put the handler in the folder you want to scan.

# April 12, 2007 3:51 PM

Neeraj said:

I am not able to use this code please help

# April 16, 2007 1:46 AM

Bertrand Le Roy said:

Neeraj: you're going to have to give more details. First check that the web site you're trying to use it on has ASP.NET 2.0.

# April 16, 2007 12:27 PM

Daniel said:

I can get the album to work great if I put it in the root of my site, but if I put it in one directory then it loads all the links, but no thumbnails....

Any ideas?

Thanks in advance!

# May 2, 2007 5:37 PM

Bertrand Le Roy said:

Daniel, please file a bug on GotDotNet.

# May 3, 2007 1:32 AM

Daniel Booth said:

Daniel, I had the same trouble getting the album to work on a directory other than root as well, but I was able to figure out what was causing the problem. Though it has been a few weeks I believe you can solve it by specifying the HandlerUrl on the control. I am pretty sure that is what I found. I don't know that it is really a bug, but it should be noted in the instructions at least. The best structure I've found is to have a Subfolder as the root of your photoalbum. Put the ashx & the display page (aspx) in this folder, and create subfolders under that for each of your "albums".
# May 16, 2007 2:13 PM

Daniel Booth said:

I love this album control. It allows me to just let my wife drop pictures out on our site, without having to change any code (good for me). My goals, as I find time, are 3 fold. 1: figure out how to change the styles to suite my site. 2: Keep the thumbnail creation and thumbnail views, but change the preview behavior to use Lightbox 2 (link below if you are interested). 3: Add comments to the pictures IF they exist. thinking of using the windows comments if I can figure out how, otherwise I may use an XML file with key pairs. Basically, just a simple way for my wife to put up comments for pictures she drops on the server. http://www.huddletogether.com/projects/lightbox2/ Anyone who has already done any of these three things please let me know. danieljb@hotmail.(dontspamme).com
# May 16, 2007 2:23 PM

Vincent said:

Hey, this is a great control! I have a question though: I have a subdirectory 'photos', it contains the ashx and aspx files as well as the directories containing the photos I'd like to display on my site. On my localhost everything works perfectly, but after I uploaded everything to my webspace (after compiling of course) I can see only the links, no thumbnails or pictures (only those little red crosses). When I try to visit a permanent link to one of the albums I get a Server Error ("invalid path - not in the handler scope"). Any ideas on how to fix this? Thanks in advance!
# May 24, 2007 10:03 AM

Vincent said:

Found the solution: the disk caching was the problem (I didn't have writing rights).
# May 24, 2007 10:40 AM

Calios said:

Nice work :) One quick suggestion: You didnt make use of the -Orientation- EXIF info in order to rotate images automatically if needed. Most of the newer cameras have a sensor to check if the cam is held horizontally or not.
# June 8, 2007 8:26 PM

Bertrand Le Roy said:

Calios: thanks for the suggestion, that's a really good point.

# June 8, 2007 9:31 PM

Calios said:

Found a little bug/annoyance - im posting it here since gotdotnet will phase out in a few days(19th of June 2k7). in CreateFolderImage you didnt fill in the BackGround - thus using any other background than black will look wierd :-O I added this to fix it: g.FillRectangle(new SolidBrush(BackGround), 0, 0, size, size); Right after the stacked Graphcis has been declared (was line 477 of the .ashx file for me - v 2.1 of the handler) :-)
# June 8, 2007 9:33 PM

Bertrand Le Roy said:

Calios: thanks for the fix.

# June 8, 2007 9:41 PM

Judge said:

How about using this in Windows Home Server? Possible? How To? etc. Pretty Please? LOL Thanks.
# June 9, 2007 4:14 PM

Bertrand Le Roy said:

Judge: I've thought the exact same thing ever since I learned about Home Server. Unfortunately, I don't own one so I can't try it. However, from what I know I don't see what could prevent it from working. If anyone wants to try, I'd love to know how it goes...

# June 10, 2007 2:48 AM

TheOfficeMaven said:

Thanks to Andrew Grant (and of course Bertrand Le Roy and Dimitry Robsman as well) this actually works great with the Windows Home Server (WHS). Andrew has written a stellar add-in for WHS that allows you to easily make this album handler work with WHS. Here's a how-to write-up that Andrew did for us all: http://www.andrewgrant.org/2007/06/09/how-to-create-a-windows-home-server-photo-album-in-minutes.html And here's the link to his WHS add-in that makes it all possible: http://www.andrewgrant.org/whiist/ -- MIKE
# June 10, 2007 1:00 PM

Bertrand Le Roy said:

Thanks Mike! This rocks!

# June 11, 2007 2:19 AM

Haywire said:

This thing is outstanding. I love it. Now, having said that, I am having one small issue. I have a folder called Pictures where the web files reside. I have dirs 2002, 2003, 2004, and in those dirs 01, 02, 03. I can get into the year folder to see my months folder, but when I click on the link for the month folder nothing happens. What is the level of folders this can handle. Root + 1? Root + inf?
# June 12, 2007 8:40 PM

Bertrand Le Roy said:

There shouldn't be a limit on the folder depth. Can you package a repro into a small zip file and send it to me at bleroy at microsoft dot com?

# June 12, 2007 9:09 PM

Russ said:

Bertrand, Kudos to you and all who contributed to this fine tool! Very easy to use and gives a great aesthetic look for a simple Photo Album. I do have a one question. I cant seem to get the stacked photos folder icon to work. I was hoping you could clarify "Stacked photos folder icons (uses default.jpg if it exists)".
# June 16, 2007 11:43 PM

Bertrand Le Roy said:

Russ: how exactly does it not work? What I meant was that if you have a photo named default.jpg, the handler will use it as the top of the stack. Other photos will be randomly selected. If you don't have a default.jpg, it takes a random photo for the top of the stack. Does that help?

# June 18, 2007 12:24 AM

Russ said:

Thanks for explaining it.  At least now i know that is not causing the issue. See the following link for my use of the Photo Album:

www.stjohnfire.com/.../Album.aspx

The album works great, but it does not show the stacked effect of the images in the album.  Not sure why this is happening.

# June 18, 2007 9:04 AM

Bertrand Le Roy said:

Russ: can you look for the UpFolderStackHeight setting in the handler and check that it's not set to 1?

# June 18, 2007 4:21 PM

Russ said:

UpFolderStackHeight  = 3

# June 18, 2007 8:42 PM

Bertrand Le Roy said:

Russ: then I have no idea, sorry. Never seen that happen.

# June 19, 2007 12:37 AM

Russ said:

I found the problem and fixed it. Since the color of my background is not black, i had made the modification suggested by Calios:

"Calios said:  

Found a little bug/annoyance - im posting it here since gotdotnet will phase out in a few days(19th of June 2k7). in CreateFolderImage you didnt fill in the BackGround - thus using any other background than black will look wierd :-O I added this to fix it: g.FillRectangle(new SolidBrush(BackGround), 0, 0, size, size); Right after the stacked Graphcis has been declared (was line 477 of the .ashx file for me - v 2.1 of the handler) :-)

# June 8, 2007 9:33 PM"

In troubleshooting deeper, i realized that i had placed this line of code in the wrong place.  it all works fantastic now.

Thanks again,

Russ

# June 20, 2007 10:06 AM

Atlas and more said:

Last night, I uploaded the source code and release package for version 2.0 of the photo handler . I'll

# June 21, 2007 1:29 AM

Atlas and more said:

I just finished migrating my PhotoHandler workspace from GotDotNet to CodePlex. I have got to say that

# June 21, 2007 3:31 AM

Richard said:

Hi, when you mention downloading code from

renaud91.free.fr/MetaDataExtractor  

it might be worth mentioning to download the

MetaDataExtractorAssembly222d.zip file

MetaDataExtractorAssembly230g.zip doesn't work.

# July 5, 2007 7:20 AM

Bas Bakker said:

Your photohandler works great in Internet Explorer.

In Firefox, however, it shows the pictures (and directories) all in one column.

Any idea how to fix this?

Thanks!

Bas

# July 7, 2007 11:10 PM

Bertrand Le Roy said:

Bas: did you make any changes to the style sheet? I just checked and it displays fine in Firefox, Opera, Safari and IE.

# July 9, 2007 1:03 PM

Sona said:

Hi

Thanks for making this tool available.

I have a small problem though. I am able to see the different folders display as groups of thumbnails. But when I click on it. It doesnt take to the album.

I really liked this implementation.

www.stjohnfire.com/.../Album.aspx

BTW: I am using Win XP Professional

Thanks,

Sona

# July 24, 2007 10:49 AM

Bertrand Le Roy said:

Sona: not sure I'm following you, it seems to work fine on your site.

# July 25, 2007 12:43 AM

John G. said:

Ok I dumped this into a folder with three pictures and recived the following.  Do you wise ones have any suggestions for me?

Thank you in advance

John G.

Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: CS0246: The type or namespace name 'com' could not be found (are you missing a using directive or an assembly reference?)

Source Error:

Line 52: using System.Web.UI.WebControls;

Line 53:

Line 54: using com.drew.metadata.exif;

Line 55: using com.drew.metadata.jpeg;

Line 56: using com.drew.metadata.iptc;

Source File: d:\hosting\jgarlie\Custom\2\album.ashx    Line: 54

# July 28, 2007 8:38 PM

Bertrand Le Roy said:

John: you forgot to drop the meta data extractor dll into the applicaiton's bin folder.

# July 29, 2007 7:25 PM

Axeman said:

Ok first and foremost thank you for this awesome app!

Now I've been trying to get this to work but to no avail. The issue I'm having is that it is scanning all my folders. I only need it to scan one specific folder and all subfolders under it. When I move the .ashx file and page to the folder that I want to show (meaning the main folder or first folder that should display) all I get are X's for all the images. Any ideas?

Also, for those interested in changing the background color and aren't necessarily using a "named" color they can substitute the

Color BackGround = Color.Black

for

Color BackGround = ColorTranslator.FromHtml("#XXXXXX")

Where the X's stand for the Hex code of the color.

Any help for my issue described above would be great!!!

# July 31, 2007 8:55 PM

Bertrand Le Roy said:

Axeman: you can try to see what the response was using Firebug or Fiddler for those images. I'd guess a trust level mismatch with your configuration. We can also continue this conversation offline (bleroy at microsoft dot com)

# August 1, 2007 2:12 AM

Beau said:

Great app!!!

Is there a way to pass a different stylesheet to the handler, or have it use a different background.  I have the app within a container on my home page and I would like to have it use a differnet background.  It keeps using the background image of the main page and I can't figure out how to change it.

thanks

# August 8, 2007 5:06 PM

Manoj said:

Great work!!! I want to definitely give it a try to integrate in my new Dating website! But before i start using the source code; is it permissible to use this code without any infringement of policies?

# August 8, 2007 10:15 PM

John G. said:

Ok I got everything to run fine on my local machine.  When I publish to my site hosted by Godaddy.com I get a problem with the following code.  Apparantly they are not giving me rights to the temporary asp.net folder this is using.  Thanks in advance for your assistance.

Static IMagehelper()

{

..

..

_imageCacheDir = Path.Combine(HttpRuntime.CodegenDir, "Album");

                   Directory.CreateDirectory(_imageCacheDir);

This  is the error:

Request for the permission of type 'System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.

# August 9, 2007 10:48 PM

Bertrand Le Roy said:

Beau: the stylesheet is inside the handler. It's very easy to change.

Manoj: the license is MS-PL. See www.codeplex.com/.../License.aspx

John: there's a setting in the handler for the cache location. Disk only works if you have a high enough trust level. Memory and none works everywhere.

# August 10, 2007 1:44 AM

John G. said:

ok I found it and changed it to memory and all is well.

Thank you

# August 10, 2007 8:48 PM

Robert Macnair said:

I get this error...

Error 1 The type or namespace name 'Directory' does not exist in the namespace 'com.drew.metadata' (are you missing an assembly reference?) C:\Users\Rob\Documents\Visual Studio 2005\WebSites\PhotoAlbum\album.ashx 58 45 C:\...\PhotoAlbum\

sorry im new to all of this and am probably being really stupid. Ive put the DLL into the Bin folder and the other errors went ragarding this reference, but this one has stayed

Thanks!

# August 22, 2007 1:14 PM

Bertrand Le Roy said:

Robert: that's weird. Are you sure you included the same version of the dll that came with the release file? Just unzipping the release in a web app should works out of the box. Does it or did you do something different from that?

# August 22, 2007 2:53 PM

Robert Macnair said:

D'Oh i was being an idiot...

I went to the link, clicked on the 'Source' tab and downloaded that. it only came with a samples folder etc and was wondering was was going on.

I must be needing sleep!

Thanks for the help Betrand

# August 22, 2007 6:58 PM

Phil Fostini said:

Just a quick question. I have 70 pictures in the share folder but only 22 show up on the web page. Am I missing something? I am using Windows Home Server RC1. My page is the above URL. I also posed this question on Andrew Grant's site.

I like how easy it is to use.

# September 27, 2007 11:52 PM

Bertrand Le Roy said:

Are all 70 photos .jpg files?

# September 28, 2007 2:14 AM

Phil Fostini said:

Actually 18 are jpeg and the balance is bitmap. Is that where I have gone wrong? The bitmaps are 1,800 - 2000 KB and the jpegs are 130 - 200 kb.

# September 28, 2007 9:37 AM

Bertrand Le Roy said:

Phil: yes, the handler only takes jpg files.

# September 28, 2007 12:03 PM

Phil Fostini said:

Thanks, I converted all to Jpeg and they all show up now

# September 29, 2007 11:06 AM

M Anderson said:

A little more explaintion of the fix for black background on thumbnails please tried

Found a little bug/annoyance - im posting it here since gotdotnet will phase out in a few days(19th of June 2k7). in CreateFolderImage you didnt fill in the BackGround - thus using any other background than black will look wierd :-O I added this to fix it: g.FillRectangle(new SolidBrush(BackGround), 0, 0, size, size); Right after the stacked Graphcis has been declared (was line 477 of the .ashx file for me - v 2.1 of the handler) :-)

but did not change anything

# October 4, 2007 7:26 PM

Bertrand Le Roy said:

M Anderson: thanks, but this is a known issue (and the project moved to Codeplex long ago):

www.codeplex.com/.../View.aspx

# October 5, 2007 1:06 PM

danilm said:

Hi, I have the same problems with

"using com.drew.metadata.exif" error.

I've downloaded latest album files (AlbumHandler2_1), extracted to wwwroot.

May I have to do anything else in IIS? (winxp)

thanks

# October 8, 2007 3:09 AM

Bertrand Le Roy said:

Danilm: I'll give you the same answer I gave to other users who had the same problem and which you can read above... You probably forgot to copy the dll into the bin directory.

# October 8, 2007 3:13 AM

danilm said:

I'm sorry but I have copied the dll into the bin directory and it doesn't work

is the right version: 2.2.2.41745?

I've downloaded AlbumHandler2_1 that contains all the files and folders

thanks

# October 8, 2007 4:57 AM

Bertrand Le Roy said:

Is the bin directory directly below the IIS application folder?

# October 8, 2007 12:35 PM

Trynyti said:

Awesome App Bertrand!  I love how easy it is to use just the .ashx page!  Now of course I have a question...

My file structure is such:

<Root>/Family/Photos/album.ashx

<Root>/Family/Photos/default.aspx

<Root>/Family/Photos/2007/<photos>

I had to change the CacheLocation to CacheLocation.Memory because of my host.

When I run just the album.ashx it works perfectly, all the images display, only the 2007 and sub-directories show and navigation works fine.  

When I try and run the default.aspx (which I modified the original to have the src="album.ashx" instead of src="~/album.ashx") I see all directories from the root (minus hidden/protected ones) and only the red X image, no images anywhere, even in the 2007 and subs, but if I click "Details" it does show the EXIF details of the photo.  The navigation still works fine, and when I get to the point where the tool tip would normally read "Click to view picture at full resolution", if I click that it opens a new browser and shows the photo as expected.

Two Questions:

1. Any idea why it doesn't show any of the photos when being called from the Default.aspx but works fine in the album.ashx?

2. How do I make it so it only scans sub-directories from it's location when being called from the default.aspx file?

Thanks for the awesome utility!

# November 1, 2007 3:45 AM

Bertrand Le Roy said:

Trinity: I think that may be a bug. Please file it on the CodePlex site.

The control will always limit what photos it displays to the directory where the handler is (not the page) and subdirectories.

# November 1, 2007 12:48 PM

cab said:

weird error..

<!-- Web.Config Configuration File -->

<configuration>

   <system.web>

       <customErrors mode="Off"/>

   </system.web>

</configuration>

and

<!-- Web.Config Configuration File -->

<configuration>

   <system.web>

       <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>

   </system.web>

</configuration>

Any Ideas ?

# November 25, 2007 5:48 PM

Bertrand Le Roy said:

Cab: what's the error?

# November 28, 2007 2:42 PM

Pedro Torres said:

Hi,

I am trying to costumize the application, although I am not being able to change the backgroudn color for the upfolder and thunbnailfolder icons... I want my background to be white and for those its in black... any one can help?

# January 12, 2008 10:32 PM

Bertrand Le Roy said:

Pedro: there are config entries in the handler as wel as forum posts and bugs on the CodePlex site that should get you started.

# January 13, 2008 8:13 PM

Mike D said:

Is there a way to have handler pull images from a certain directory?

Example file structure:

Bin

App_Data

images

---->Folder 1

---->Folder 2

---->Folder 3

defualt.aspx

ablum.ashx

# January 23, 2008 5:29 AM

Bertrand Le Roy said:

Mike: why don't you put the handler in the images folder?

# January 23, 2008 1:12 PM

ttoomm said:

Bertrand-

You should not have blown M Anderson off like that.  He/She is reporting a different issue (October 4, 2007 7:26 PM.)

1. Calios'  June 8, 2007 fix for the background of the stacked  Folder Immages works just fine.  So it is no longer a "known issue" but rather a fixed issue.

2. What M Anderson is reporting is a peculiarity that I do not fully understand but can discribe.  If you make the change Calios describes, the thumbnails don't change until you change the folder names.  The thumbnails are stored in the application's temporary folder, background and all.  They do not change just becuase you say you wnat them to look different.  You have to do something to cause them to re-write.

# January 27, 2008 12:45 PM

Bertrand Le Roy said:

ttomm: right, and this is a known issue too. If you want to regenerate the thumbnails, for the moment, you need to physically delete them or somehow restart the appdomain (touching web.config should do the trick). The original issue is not fixed in the sense that the fix is not yet in the current release, so it's a "known fix" rather than a "fixed".

# January 28, 2008 2:35 PM

Jeff said:

Awesome little app, however I have some issues with it, when I add the required files to the directory, it shows everything as it is supposed to, however when I click on an image, to see if in the center of the screen, it doesnt show at all, it only shows the 'Details', 'Previous Image' and 'Return to Folder View'.

I like this app very much, but I would LOVE for it to show the image in the center of the screen.

I'm running this on WHS (Home Server) and the client OS is Vista, with IE7.

# February 21, 2008 11:14 PM

Bertrand Le Roy said:

Jeff, please contact me  through the contact form, and I'll look into it.

# February 22, 2008 1:54 PM

Cathy said:

Hi Bertrand,

I want to change background color of thumbnail. I changed the following code:

private static readonly Color BackGround = Color.White;

However, the color remains blank.

Please help. Thanks.

# February 26, 2008 10:12 PM

Bertrand Le Roy said:

Cathy: that's this issue:

www.codeplex.com/.../View.aspx

The bug is not fixed in the current release but the discussion on it contains a fix.

# February 27, 2008 12:55 PM

Lou said:

hello, seems to be a nice album, but it's not working on my hoster. sohosted.com

I also have this problem:

The issue I'm having is that it is scanning all my folders. I only need it to scan one specific folder and all subfolders under it. When I move the .ashx file and page to the folder that I want to show (meaning the main folder or first folder that should display) all I get are X's for all the images. Any ideas?

sohosted.com is running on medium trust, changin the location of the cache to none or memory doesn't fix the problem....

somebody knows what to do?

Regards

Lou

# March 3, 2008 8:04 AM

Bertrand Le Roy said:

@Lou: it seems like you're using the user control version. If that's the case, you can try to set the HandlerUrl property to point at the ashx file, and also the Path property on non-postback requests.

# March 3, 2008 2:28 PM

Sridhar said:

Hi,

  Thanks for writing such a nice tool. I have tried on my website and everything works fine. However there is one photo that doesn't show the details when I use the aspx page and clicked on it. If I use the Album.ashx the same photo displays the details. To experience this behavior please go to

www.tampatennisleague.com and click on photo gallery. for now I set the url to Album.ashx to display the images. If you go to that page, you will see two photos. The first image is the one that I am having issues. If you go to www.tampatennisleague.com/.../photogallery.aspx you will see the same photo. And if you click on it, it doesn't display the details.

I am not sure what could be wrong?

Thanks,

sridhar.

# March 15, 2008 11:13 PM

Bertrand Le Roy said:

Sridhar: I have no idea. The image isn't even in the dom. Drop me e-mail at bleroy at microsoft com and we'll try to debug into it.

# March 17, 2008 1:31 PM

MichaelR said:

Great Work...

All is working well in my local machine. But when I publish it on my website and click on my Gallery Menu...

It is prompting me a user name and password and not allowing me to access my gallery...It has something to do with the permission with my host...but When   I checked my rights I have drwx...

Is there something else that I need to changed in the codes...Can somebody please give me some suggestion that I can try to make it work....or If somebody encountered the same problem please let me know what to do. I already changed the Caching to Memory but still the same...

Thanks very much in advance.

MichaelR

# March 30, 2008 4:47 PM

Bertrand Le Roy said:

@Michael: I have no idea. You should check that with your hoster. Let me know what you find.

# March 30, 2008 5:11 PM

MichaelR said:

I was wrong...Memory Caching sorted it out.

But I get some links and red croses though in some of

the pictures though...Is this a bug or Is there a work around with this.

Thanks very much

# April 1, 2008 3:40 AM

Bertrand Le Roy said:

@Michael: are the broken images consistently the same images? Are they jpeg images? Is there a public url where I could have a look?