I would like to detach all attachments to a folder

I am trying to auto detach attachments to a local folder on my system whenever there is an email attachment is this possible?

Subject: Yes, via the EmbeddedObjects property of the NotesRichTextItem class