hi, i am trying to cylce through attachments within the same item, however it seems to be giving the right amount however it is the same attachment per record, as opposed to 3 seperate attachments per record, the code i have is as follows
Dim count2 As Integer
Set db=ns.CurrentDatabase
Set pView=db.GetView("forexport2"
pView.AutoUpdate=False
SavePath="c:\Photos\"
Set pDoc=pView.GetFirstDocument
While Not pDoc Is Nothing
count2 = 1
Set rtItem=pDoc.GetFirstItem("Imagev"
'If (rtItem.Type=RICHTEXT) Then If Not Typename(rtItem.EmbeddedObjects)="EMPTY" Then
Forall o In rtitem.embeddedobjects
count2 = count2 + 1
If (o.Type=EMBED_ATTACHMENT) Then
Call rtItem.EmbeddedObjects(0).ExtractFile(SavePath & pDoc.PanelKey(0) & "_" & count2 & ".jpg"

End If
End Forall
End If
Set pDoc=pView.GetNextDocument(pDoc)
Wend
End Sub