MSMVPS.COM
The Ultimate Destination for Blogs by Current and Former Microsoft Most Valuable Professionals.
PDF icon in Companyweb

Blogs

Aimless Ramblings from a Blithering Lunatic . . .

Syndication


Ok - if you're like me, you have a list a mile long of those little things you want to fix / research / figure out / or just play with - and it seems that life has a tendency to make digging through that list take longer than we'd like . . .

Well, one of the little things on my list was getting icons for pdf files to display in my Sharepoint document libraries.  I googled the answer months ago, but just never got around to doing it.  Well - with more and more customers using Sharepoint, it was definitely time to take care of this, and make it easy to configure on multiple servers.

The process to do this is fairly simple - we find a 16x16 pdf icon and put it in the c:\program files\common files\microsoft shared\web server extensions\60\template\images directory.  Then we open the c:\program files\common files\microsoft shared\web server extensions\60\template\xml\docicon.xml file, scroll down to the 'By Extension' section and add the entry 

That's all fine & dandy - but I really dislike manual, repetitive steps - so I automated it   :)   I started with a docicon.xml file from a clean SBS install and added the necessary entry for the pdf extension.  I then took the updated docicon.xml file, the 16x16 pdf image (pdf16.gif), and a simple batch file (pdficon.bat) that will put the files where they need to be and combined them all into a nice little zip file that you can get here.

Just download the file to your server, unzip & run the pdficon.bat file (locally on your server), and you should be good to go!  Note that the batch file doesn't overwrite your existing docicon.xml file - it renames it to docicon.old before putting the updated file in the directory - so if you need to go back to the original for whatever reason, it's just a matter or renaming files. 


Posted Tue, Oct 26 2004 0:03 by cgross
Filed under: ,

Comments

TrackBack wrote Get that PDF icon on your SharePoint Sites!
on Tue, Oct 26 2004 0:15
TrackBack wrote Get that PDF icon on your SharePoint Sites!
on Tue, Oct 26 2004 3:57
cgross wrote re: PDF icon in Companyweb
on Tue, Oct 26 2004 8:16
Thank you Chad. I never thought of creating a batch file to add the icon. I've been doing it manually this whole time.
By the way, how's the WSS CRM coming? Do you have an ETA for download availability?

Thank you again.
TrackBack wrote PDF's in SharePoint sites
on Tue, Oct 26 2004 9:43
cgross wrote re: PDF icon in Companyweb
on Sun, Nov 7 2004 17:15
Whoop Whoop!

Thanks Chad, I have been doing this manually for ages ;-)

Nick
cgross wrote re: PDF icon in Companyweb
on Tue, Nov 23 2004 7:07
Thanks. it saves time and xml hunting :D
TrackBack wrote As we pause for a moment of silence for our
on Tue, Nov 23 2004 19:36
TrackBack wrote As we pause for a moment of silence for our "Sharepoint" Anniversary
on Tue, Nov 30 2004 14:13
Today, well, actually I mean tomorrow, but in reality today ...
cgross wrote re: PDF icon in Companyweb
on Sat, Dec 18 2004 14:53
thats pretty cool.

Do we still need to install adobe ifilter for full text index functionality?
cgross wrote re: PDF icon in Companyweb
on Wed, Dec 22 2004 16:53
That did the trick! Thank you for your easy to use installation!
cgross wrote SPS and pdf files
on Sat, Jan 8 2005 13:35
Thanks, but how can I make it possible to open the pdf-files with a rigth click:
EditText="Adobe Acrobat" OpenControl="SharePoint.OpenDocuments"/> When I rigth click the text Adobe Acrobat is comming up,(Edit with Adode acrobat) but I get an error when I open the file.


What should I write instead of "SharePoint.OpenDocuments"?
cgross wrote re: PDF icon in Companyweb
on Thu, Feb 24 2005 17:49
How do you get the PDF file to become a ThumbNail of what the document is - at least the first page of the file?
cgross wrote re: PDF icon in Companyweb
on Mon, Feb 28 2005 6:14
hi chad that is really cool,

can u please suggest any solution to maintain version history for PDF files .(i.e editing the files from sharepoint )

regards
TrackBack wrote customize SharePoint Schema Files
on Sat, Mar 12 2005 19:54
cgross wrote re: PDF icon in Companyweb
on Mon, Mar 21 2005 14:25
Thanks Chad....awesome.
cgross wrote re: PDF icon in Companyweb
on Mon, Mar 21 2005 14:43
Thanks a lot, this was just what I was searching for - and more - due to the nice batch file.

Suggestion for possible improvement:
usage of %CommonProgramFiles% so the batch file works on all language versions.

btw: I'm from Germany :-)

Thanks again. Worked like a charm after adopting to german OS.
cgross wrote re: PDF icon in Companyweb
on Mon, Mar 21 2005 18:45
NICE!!!!!!!!!!
cgross wrote re: PDF icon in Companyweb
on Wed, Mar 23 2005 9:40
Great help and worked first time :-)
For full text search in Share Point there is this article from Microsoft http://support.microsoft.com/default.aspx?scid=kb;EN-US;832809
The Adobe PDF IFilter 5.0 has been replaced to version 6.0.
I downloaded the latest PDF IFilter 6.0 from Adobe here - http://www.adobe.com/support/downloads/detail.jsp?ftpID=2611
My users can find any text in PDF files now!
cgross wrote re: PDF icon in Companyweb
on Fri, Mar 25 2005 20:23
Thanks a bunch! That is a very useful bat file we will be putting to good use when we roll our Large Server Farm.
cgross wrote re: PDF icon in Companyweb
on Tue, Apr 5 2005 4:07
How do you get the PDF file to become a ThumbNail of what the document is - at least the first page of the file?
TrackBack wrote re:PDF icon in Companyweb
on Thu, Apr 14 2005 8:11
^_^,Pretty Good!
cgross wrote re: PDF icon in Companyweb
on Wed, Apr 20 2005 5:00
Hier bitte Bacht-Datei für ein deutsches Betriebssystem:

@echo off
ECHO Adobe Acrobat PDF icon installation script for Windows Sharepoint Serivces document libraries by Chad Gross.
copy pdf16.gif "C:\Programme\Gemeinsame Dateien\microsoft shared\web server extensions\60\template\images\pdf16.gif" /y
rename "C:\Programme\Gemeinsame Dateien\microsoft shared\web server extensions\60\template\xml\docicon.xml" docicon.old
copy docicon.xml "C:\Programme\Gemeinsame Dateien\microsoft shared\web server extensions\60\template\xml\docicon.xml" /y
iisreset
cgross wrote re: PDF icon in Companyweb
on Wed, Apr 20 2005 17:19
Sweet! Thank You so much! That was a flawless solution to the problem. Chad, You're awesome.
cgross wrote re: PDF icon in Companyweb
on Fri, Apr 22 2005 20:00
THANK YOU!!!
cgross wrote re: PDF icon in Companyweb
on Mon, May 9 2005 9:30
Thanks it worked great!
cgross wrote re: PDF icon in Companyweb
on Wed, Jun 8 2005 10:00
Thanks, good thinking, neat tool!
cgross wrote re: PDF icon in Companyweb
on Thu, Jun 9 2005 2:23
Doesn't work if you don't use the C drive. Does anybody remember what the batch file command is for the local drive? I changed it manually for a temp hack.

malcolm@einnovations.com
cgross wrote re: PDF icon in Companyweb
on Thu, Jun 23 2005 10:41
Thanks, worked like a charm.
TrackBack wrote Index PDF documents within Sharepoint
on Wed, Jun 29 2005 17:27
cgross wrote re: PDF icon in Companyweb
on Fri, Jul 22 2005 12:51
Cool ! Perfect Job. Thanks a lot !
Goran Matic wrote re: PDF icon in Companyweb
on Wed, Dec 21 2005 15:26
Didn't work. I checked and double checked and nothing out of the ordinary. Is there a service I have to restart in order for these changes to take effect?
Bob DeVeaux wrote re: PDF icon in Companyweb
on Tue, Feb 28 2006 4:38
Excellent. Thank you very much!
Sindre Døvigen wrote re: PDF icon in Companyweb
on Mon, Apr 24 2006 4:14
Great stuff - worked perfect. Thank you !
Brad Folger wrote re: PDF icon in Companyweb
on Fri, May 26 2006 14:28
Worked flawlessly - much appreciated!
Michel wrote re: PDF icon in Companyweb
on Tue, May 30 2006 15:49
Worked like a charm.

Too cool for school!
Mike Smith wrote re: PDF icon in Companyweb
on Tue, Jun 6 2006 16:04
Worked perfectly. Thanks for posting!
Remy wrote re: PDF icon in Companyweb
on Sat, Jun 10 2006 15:17
Thanks!
Russell Waltz wrote re: PDF icon in Companyweb
on Wed, Aug 2 2006 9:33
You are awesome!!!  Thanks for making my life a little easier.
trox wrote re: PDF icon in Companyweb
on Wed, Aug 9 2006 15:10
awesome work! seamless! that thing has been buggin the crap out of me for months. thanks a lot!
Brenda C wrote re: PDF icon in Companyweb
on Wed, Aug 16 2006 16:04
Worked great. Good job, You're awesome!!!!
Kevin Wilson wrote re: PDF icon in Companyweb
on Fri, Aug 25 2006 18:26
I'm really embarrassed to admit this, but I haven't been able to get the manual method to work!!! Seems simple enough, but when it's done I still have no icon next to pdf documents. They open OK, just no icon...
Bill wrote re: PDF icon in Companyweb
on Thu, Sep 14 2006 12:05
I am having the same problem as Kevin Wilson. I had this working in my test environment using 5.0, but I rebuilt the sharepoint server and so decided to use 6.0. Followed the same steps as 5.0 instructions made available by Microsoft in KB 555209, but now the Icon does not show next to the documents in the libraries. Any ideas? Thanks.
Brian W wrote re: PDF icon in Companyweb
on Fri, Sep 15 2006 14:41
Worked great. Thanks! You have to restart IIS through Computer Management for those not seeing the new icon.
Sebastian wrote re: PDF icon in Companyweb
on Sun, Sep 24 2006 21:06
Worked perfectly thankyou!!
Dearg O'Bartuin wrote re: PDF icon in Companyweb
on Thu, Oct 19 2006 7:22
Thanks Chad, This bugged me for far too long, now im a very happy bean :)
Mark Wormald wrote re: PDF icon in Companyweb
on Wed, Oct 25 2006 6:03
Thankyou - solved a personal & customer irritation Thanks
nick allen wrote re: PDF icon in Companyweb
on Wed, Nov 1 2006 9:19

this solution worked for displaying the adobe icon in document libraries, but the adobe icon is not displayed next to listings created for the document library entries. Is thjere a way to configure this also or must one reset the image & icon graphic for each listing to an adobe document manually?

thanx,

nick

cgross wrote re: PDF icon in Companyweb
on Thu, Nov 2 2006 13:09

Nick - I have a few questions for you.  Use the contact link to email me so we can discuss offline . . .   Thanks  Chad

Technology » 2006 » November » 28 wrote Technology » 2006 » November » 28
on Tue, Nov 28 2006 13:04
Patrick wrote re: PDF icon in Companyweb
on Wed, Nov 29 2006 8:51

You are the man!  Thank You So Much!

SBS 2003 R2 Premium Installation » Joint Technologies ltd » Blog Archive wrote SBS 2003 R2 Premium Installation » Joint Technologies ltd » Blog Archive
on Thu, Jan 4 2007 18:39
on Mon, Feb 5 2007 1:01

Ever since I blogged about my batch file to simplify the task of getting a PDF icon to display in SharePoint

NoGeekLeftBehind.com » Blog Archive » SharePoint PDF Icon Tool Gets Even Better wrote NoGeekLeftBehind.com » Blog Archive » SharePoint PDF Icon Tool Gets Even Better
on Wed, Apr 11 2007 12:19
SBS2003 and network wrote 101 SBS Tip - 3. Přidání ikony pro pdf do Sharepoint Services
on Wed, May 2 2007 0:15

PDF icony na companyweb (Sharepoint) Možná jste si již všimli že když přidáte v SBS 2003 na companyweb nějaký PDF dokument, není zobrazena hezká pdf ikona jako v případě ostatních třeba Office dokume ...

Matt Johnson's Technical Adventures wrote WSS and SharePoint 2003 File Icons
on Sat, Jun 2 2007 19:00

Now that I have Office 2007, I wanted my SharePoint sites to recognize the new file icons. Office 2007

FG wrote Post Sharepoint 2007 / WSS 3.0 ToDos: Enable PDF in search and display
on Tue, Jul 10 2007 16:05

Fix PDF in search of WSSS 3.0 and MOSS 2007 - Install Acrobat Reader 8 on the Sharepoint Webserver -

luka.manojlovic.net » Blog Archive » Windows Sharepoint services z dodatnimi ikonami za datoteke z NE-Office kon??nicami. / Windows Sharepoint services with additional icons for NON-Office files extensions. wrote luka.manojlovic.net » Blog Archive » Windows Sharepoint services z dodatnimi ikonami za datoteke z NE-Office kon??nicami. / Windows Sharepoint services with additional icons for NON-Office files extensions.
on Tue, Jan 1 2008 10:59

Pingback from  luka.manojlovic.net  » Blog Archive   » Windows Sharepoint services z dodatnimi ikonami za datoteke z NE-Office kon??nicami. / Windows Sharepoint services with additional icons for NON-Office files extensions.