cancel
Showing results for 
Search instead for 
Did you mean: 

StoreNewDocument() Overloads

Vince_Fedorchak
Champ in-the-making
Champ in-the-making

What is the purpose of the additional overloads for the Storage.StoreNewDocument() method?  These are the overloads to which I'm referring:

StoreNewDocument(IEnumerable(PageData), StoreNewDocumentProperties)
StoreNewDocument(IEnumerable(String), StoreNewDocumentProperties)

When I attempt to create a document with either of those overloads (a List<PageData> with valid PageData or List<string> with valid filenames), the document is created but only the first index is used for the new document's contents.  How can I use these overloads to combine multiple documents or PageData objects into one big document?

We are using OnBase 11.

Thanks.

3 REPLIES 3

Patrick_Ramser
Star Contributor
Star Contributor

Hey Vince,

The intent is for the list of Page Data or page locations, by string, to use all of those pieces of data for the upload. The new document should contain all that information as different pages. What type of file format are you uploading where this isn't working?

Patrick_Ramser
Star Contributor
Star Contributor

Hey Vince,

Is this still failing for you when using the different page lists?

Vince_Fedorchak
Champ in-the-making
Champ in-the-making

After working with API support and our support vendor, we determined that the StoreNewDocument() overloads will properly combine PageData only when the Image data provider is used.  PDF PageData will not be combined, even when combined exclusively with other PDF PageData.

Our solution was to purchase the PDF Framework license and associated files which enables us to convert PDF PageData to Image PageData by retrieving PDF PageData via the Image data provider.  We then get all document PageData using the Image provider, check in the new Document as an 'Image' File Type, and immediately create a new PDF rendition of the document.  It's a bit of a workaround (and the performance of the PDF Framework conversion leaves something to be desired) but it works sufficiently for our needs and can be done via pure Unity scripting.