Can we share PDF or other documents using JSQMessanger? - ios

We want to share PDF or other documents using JSQMessanger. Because we have used JSQMessanger for chating in our App.

You should expand JSQ functionalities for the PDF source

Look at how the example app does media items i.e. Video or images. It will be similar to this and then you just need to adapt it so that it can handle the PDF payload. Definitely a great thing to add to the library.

Related

Can we share PDF with drawings in other applications using PDFKit in Swift?

I am using PDFKit to edit, draw and then share PDFs in other applications like mail, WhatsApp, etc.. Able to share the file after editing but when I try to share the PDF after drawing something, I am unable to share it. Those drawings are not there in the PDF after sharing. Please tell me, can we share the PDF with drawings using PDFKit?
Make sure you save your pdf file into the local storage and next the easiest approach would be to use the UIActivityViewController to share the file.

How to share a bunch of files at once in iOS

I need to share some data, e.g. two images, to other apps like dropbox or gdrive.
Some recommend using UIActivityViewController but there's no option for mimetypes and other recommend using UIDocumentInteractionController but this seems only be suitable for single files...
Does anybody know about the right way and/or can provide some example in swift?
Edit:
UIActivityViewController seems to be the right way and NSURL.fileURLWithPath(filePath) provides the content.
But what about files stored on a server? Those must be downloaded at some point during share process (e.g. after choosing dropbox). How can I achieve this? I tried with a customized UIActivityItemSource with no luck.
Thanks.
Take a look at the Apple doc for UIPasteboard.
Using UIActivityViewController is the right way.
I had to provide my files wrapped in a subclass of UIActivityItemProvider.
Overriding item()-function for downloading and providing my binary content.

iOS - Is there a way to generate a PDF file with layers?

Quick question, that I haven't found a solid answer yet.
Is it possible to generate a PDF in iOS that includes layers, which can then be removed/separated in Photoshop?
What I'm trying to achieve is take a picture with the camera of the phone, then place text over it, submit it as pdf to a customer and then have the customer read the text and remove it.
I can do everything except the layering of the pdf and I have found some hints that this isn't possible to do with the standard iOS library, but I wanted to know if anyone has come across this before.
Thank you.
The standard iOS API for creating PDF files cannot create layers (optional content) in a PDF page.
This library IFXPDFFactory seems to be able to generate PDF files with layers.
PoDoFo and libHaru can also be used to generate PDF files on iOS but I do not know if they support layers.

building a document preview webpage

Hi i'm wanting to create a webpage in which i can pass a url to a document and it previews it. the idea behind this is so i can create a responsive web view for android so i can preview documents from with an app i have basic knowledge of php and html but if some one could point me in the right direction? i have had a look around but can't find anything that basic i don't need to edit the documents just view them. Does anyone know how to do this?
ps: the docs i want to preview are .xl .xls .doc .docx .pdf .ppt etc
Here is what looks to be a decent open source option.
http://flexpaper.devaldi.com/
One option would be to convert the documents to .pdf first using OpenOffice and then preview them using pdf.js

PDF generation in XCode

I am a newbie in iPhone development. I am planning to do a PDF application for iPhone. The functionality is:
User will type their input in a text field (which is going to be the content of the PDF file).
I have to modify the PDF file through code while saving (paragraphs, tables, bullets etc).
User can save it in their own name.
User can send the PDF file as attachment of MFMailComposer.
So I have searched and got many links. However I didn't find any leading details to create and modify a PDF file in iPhone/iPad.
Can anyone please provide me a good reference to do this. Are there any alternatives to do this?
I've used this reference: https://developer.apple.com/library/ios/#documentation/GraphicsImaging/Conceptual/drawingwithquartz2d/dq_pdf/dq_pdf.html
It contains theoretical explanations and source code examples
Please use the below link to download sample apps for PDF Reader/Viewer in iOS
PDF Reader/Viewer in iOS
Also please look at detail about pdf creation, manipulation etc in below links
developer.apple: PDF Document Creation, Viewing, and Transforming
Fast-and-lean-pdf-viewer-for-iphone
If you were doing a Phonegap app I'd say got for jsPDF, which would enable you to create (basic) PDF files in Javascript. I don't do Obj-C, but a quick look on SO provides good links.

Resources