This question sounds pretty interesting.We all know that we can access the list items from the list easily. Perhaps we may not be had used this concept.Yes we cam access the attachment of the list item in this way:
foreach(string filename in listiem.Attachments)
{
SPFile file=listItem.parentLis.ParentWeb.GetFile(listItem.Attachments.UrlPrefix+filename);
//do whatever u wanted to do
}
foreach(string filename in listiem.Attachments)
{
SPFile file=listItem.parentLis.ParentWeb.GetFile(listItem.Attachments.UrlPrefix+filename);
//do whatever u wanted to do
}
Comments