|
|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。如果您注册时有任何问题请联系客服QQ: 83569622 。
您需要 登录 才可以下载或查看,没有帐号?注册
x
Write:
Dim session As New NotesSession
Dim db As NotesDatabase
Dim doc As NotesDocument
Dim rtitem As NotesRichTextItem
Dim object As NotesEmbeddedObject
Set db = session.CurrentDatabase
Set doc = New NotesDocument( db )
Set rtitem = New NotesRichTextItem( doc, "Body" )
Set object = rtitem.EmbedObject _
( EMBED_ATTACHMENT, "", "c:\jim.sam")
doc.Form = "Main Topic"
doc.Subject = "Here's Jim's document, as an attachment"
Call doc.Save( True, True )
Read :
Set item= doc.GetFirstItem( "Body" )
itemType = item.Type
flag = doc.HasEmbedded
If (itemType=RICHTEXT And item.values<> "" And flag=True) Then
Forall o In item.EmbeddedObjects
Select Case o.Type
Case EMBED_ATTACHMENT:
filename =AttachPath+ MemoID+"_"+DocNo+"_"+o.Name
Call o.ExtractFile(filename)
Call ToSQL_Attach(MemoID,o.name)
End Select
End Forall
End If
|
|