Created: 1/28/2010
Modified: 7/21/2014This method demonstrates how to populate an image field in a LiveCycle form using FDF Toolkit .net and VB.net.
Private Sub ImageFieldManipulations()
' INSERTS IMAGE IN IMAGE FIELD ON LIVECYCLE FORMS
Dim cFDFApp As New FDFApp_Class()
Dim cFDFDoc As New FDFDoc_Class()
cFDFDoc = cFDFApp.FDFCreate
cFDFDoc.XDPAddForm("subform1", Server.MapPath("test_livecycle-image1.pdf"))
cFDFDoc.XDPAddField("FullName", "Bo Duke", "subform1", FDFDoc_Class.FieldType.FldTextual)
cFDFDoc.XDP_Add_ImageField("Image1", "subform1", Server.MapPath("Signature_01_Small.jpg"), True)
Response.Clear()
' WRITE XDP DATA TO BUFFER
Response.ContentType = cFDFApp.MimeXDP
Response.BinaryWrite(cFDFDoc.FDFSavetoBuf(FDFDoc_Class.FDFType.XDP, True))
' WRITE MERGED XDP/PDF TO BUFFER
'Response.ContentType = cFDFApp.MimePDF
'Response.BinaryWrite(cFDFDoc.PDFMergeXDP2Buf(Server.MapPath("test_livecycle-image1.pdf"), False, ""))
' WRITE MERGED XDP/PDF TO FILE
'cFDFDoc.PDFMergeXDP2File(Server.MapPath("test_livecycle-image-MERGED.pdf"), Server.MapPath("test_livecycle-image1.pdf"), False, "")
Response.End()
End Sub
Go back to Development, Design & Programming Tutorials section