Sherry, can you just do it like this
<img src='/images/<%# ((string)Eval("DocumentType")).Replace(".","") %>.gif' alt="icon" />
<%# ((string)Eval("DocumentType")).Replace(".","") %> will give you extensions like pdf, rtf, etc. Then you just need a list of .gif for all the types stored in a images folder.