➢ I actually dont want to export anything to do with the embedded videos, a
To exclude rich media annots you could traverse all annotations before export to FDF / XFDF and temporarily remove references to these annotations from page (see Annotation sample project - http://www.pdftron.com/pdfnet/samplecode.html#Annotation).
Hi,I have just tested working code with another PDF, one which contains a Rich Media annotation (an embedded video) and my app now crashes in this function (see the comment). This is an iOS app.-(void)exportAnnotations{
if([Utils IsConnectedToInternet]){
NSString *docFilename = @"document";
FDFDoc *doc = [docToOpen FDFExtract:e_annots_only];
[doc SetPDFFileName:[NSString stringWithFormat:@"%@/%@.pdf", pdfFolder, docFilename]];
[doc SaveFDFDocToFile:[NSString stringWithFormat:@"%@/%@.fdf", pdfFolder, docFilename]];
[doc SaveAsXFDF:[NSString stringWithFormat:@"%@/%@.xfdf", pdfFolder, docFilename]]; //Crash here
//More code which i have not included to do with uploading the saved .xfdf file
}
}
and shows this in the console:*** Terminating app due to uncaught exception 'PDFNet Exception', reason: 'GetAt() can't be invoked on Obj of this type.'
When I say "working code" I mean code which works perfectly well with a 2 different PDFs which don't contain an embedded video.
I actually dont want to export anything to do with the embedded videos, as I guess it will bloat the .xfdf file I am uploading (which needs to be small as its frequently uploaded). So, if the problem is the embedded video, I guess my real question is: How can I export annotations to an XFDF file, but exclude any rich media annotations?
Thanks,
Mike