You are viewing limited content. For full access, please sign in.

Question

Question

Laserfiche download to PDF: Can the metadata be transferred into the PDF properties automatically or through a workflow?

asked on February 23, 2022

I have a client who want to be able to download files from the repository and have them retain the metadata attached to the original laserfiche file. Does anyone know of a way that could be done? By default our files download from original tif into PDF. Thanks!

0 0

Replies

replied on February 23, 2022

With Workflow you could map the metadata to a PDF field if that is what you're asking.

1 0
replied on February 24, 2022

That is exactly what I am thinking, but have no idea how to map that into a workflow....

0 0
replied on February 23, 2022

If the destination for these downloads is another Laserfiche system, you could export as Laserfiche Briefcases, an XML-based format which contains both the files and their metadata.

0 0
replied on February 24, 2022

I would be uploading into a SharePoint library.... so briefcase wouldn't work, which is too bad. That would make things easier lol

0 0
replied on February 24, 2022

 

You can write to the .pdf's custom properties with iTextSharp

 

using iTextSharp.text.pdf; 

.....

using (PdfReader reader = new PdfReader(fullFileName))
            {
                using (FileStream fs = new FileStream(pdfStamped, FileMode.Create, FileAccess.Write, FileShare.None))
                {
                    using (PdfStamper stamper = new PdfStamper(reader, fs))
                    {
                        Dictionary<String, String> info = reader.Info;
                        foreach (KeyValuePair<string, string> props in properties)
                        {
                            if(info.ContainsKey(props.Key))
                            {
                                info.Remove(props.Key);
                            }
                            info.Add(props.Key, props.Value);
                        }

                        stamper.MoreInfo = info;
                        stamper.Close();
                    }
                }
            }

 

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.