Sorry, could you clarify a bit ?
Does your problem concern cycling the items in the document, cycling attachments in the document, or cycling the documents in the view ?
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
Where are the Dims? If you declare these in the Declarations event, fair enough, but you need to declare variables before you use them...
Also, your Ifs and your End Ifs don't add up...
Sorry if this is no help at all, but I'm not at the stage of reading code fluently yet, and I don't have time to explore yours at the moment! But are you already aware of these two points?
I've had problems with Domino Designer 6 removing my End If statements, apparently at random, which is very annoying! When you save a form, make sure youselect a field or event with no code in it, then save, and then it doesn't remove your code!
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.