Hello,
I have Memorystream of image like tif flie. Now i want to convert this memorystream to pdf file.
I did code as below
Dim docBytes As Byte()
Dim Doc12 As PDFXEdit.IPXC_Document
docBytes = GetBytesFromFile("Here is my tiff file")
Dim _FileMemorystream As New MemoryStream(docBytes)
Dim srcIStream As IStreamWrapper = New IStreamWrapper(_FileMemorystream)
Doc12 = iConv.Convert(CType(m_Inst, PDFXEdit.PXV_Inst), srcIStream)
m_nID = m_Inst.Str2ID("op.imagesToDoc", False)
Op = m_Inst.CreateOp(m_nID)
Input = Op.Params.Root("Input")
Input.Add().v = fsInst.DefaultFileSys.StringToName(data.sDoc)
Dim options As PDFXEdit.ICabNode = Op.Params.Root("Options")
m_Inst.AsyncDoAndWaitForFinish(Op, 0)
Dim output As PDFXEdit.ICabNode = Op.Params.Root("Output")
Dim newCoreDoc As PDFXEdit.IPXC_Document
newCoreDoc = CType(output(0).Unknown, PDFXEdit.IPXC_Document)
newCoreDoc.WriteToFile("C:\Users\Vivek\Documents\Docsvault Checkout Folder\NewPDF.pdf")
Op.Do()
Doc12.Close()
so, how to convert image(memorystream) to pdf ?
Regards.
image to pdf.
Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan
Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.
When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.
When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: image to pdf.
Hello vivekpatel,
From what I see, that operation does not support the IStream as an input:
https://sdkhelp.pdf-xchange.com/vie ... magesToDoc
The best way would be to open the document directly from IStream like you did here:
https://www.pdf-xchange.com/forum3 ... morystream
Cheers,
Alex
From what I see, that operation does not support the IStream as an input:
https://sdkhelp.pdf-xchange.com/vie ... magesToDoc
The best way would be to open the document directly from IStream like you did here:
https://www.pdf-xchange.com/forum3 ... morystream
Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ