document renaming

Mar 8, 2012 at 3:16 PM

This works like a charm in terms of importing documents and applying metadata.

The part I cannot figure out is why it renames my documents according to the library into which it is going. For example, if, via the script arguments, I point to a folder that contains the file Agenda.docx, specify a column name that contains a value of "Meetings" via manifest, and specify that the document be moved into the Shared Documents library, all goes as planned, except that the document gets renamed from "Agenda.docx" to "SharedDocumentsAgenda.docx".

Ideas on what I can modify to avoid this?

Mar 8, 2012 at 4:04 PM

Figured it out. Must specify the parameter -FlattenStructure even if the directory from which the files are being imported is already flat. This causes the code at/around line 89 to change the way the file is named.

Hopefully, it is not bad form in this forum to answer one's own question. If so, please forgive. Just trying to keep someone else from my mistake.