Friday, January 22, 2010

Adding Adobe PDF icon to Document Library

I was playing around with a document library. I uploaded a PDF file to the document library and I noticed that it displayed a white icon next to the PDF item instead of PDF icon which we see in our system. After digging more into this, here is how I got it resolved:

Let's do step by step:

  1. Download the PDF icon from Adobe website (I chose 17x17 icon)
  2. Save the above GIF image into "12\TEMPLATE\IMAGES" folder
  3. Go to "12\TEMPLATE\XML" folder and open DOCICON.XML
  4. Under ByExtension tag, add a Mapping element for PDF GIF image.
  5. Key = "pdf" Value = "pdficon_small.gif"

  6. Save DOCICON.XML file
  7. Do IISRESET
  8. Refresh your page.

Bingo! For all PDF files, it displays the correct PDF icon!

1 comments:

  1. Hi there,

    I am facing a problem in SharePoint, and I posted it on SharePoint Products and Technologies Forums.
    Could you please please please have a look at it, and kindly do contribute with any thought(s), idea(s) or approach(es) that might help me to find a solution.

    The URL of the entry where I posted my problem is:
    http://social.msdn.microsoft.com/Forums/en-US/sharepointdevelopment/thread/8f7b9b1a-8c13-455e-8cb1-f7b7003049b0

    I would greatly and sincerely appreciate your input, I really need your help!

    Thank you for your consideration of my request.

    Best regards,
    Alejandro

    ReplyDelete