Hi, the full documentation for that is :
Document.importFile (importFile: File , isLinked: Boolean , libraryName: string , itemName: string , elementRef: string , modifiedTime: number , creationTime: number , adobeStockId: string , adobeStockLicense: string )
So it seems only relative to importing file from Creative Cloud Libraries, and the 1st argument should be Path (or the URL) to the library file. But still don't know what that is like. The 2nd argument will be true or false, all the others are optional.
As an option, try:
activeDocument.importFile( File('your file path') );
Thanks moluapple and Alexander LAdygin
For other people, you can use the Object Model Viewer for looking all functions available.
On Mac go to Help -> Object Model Viewer.
Didn't know about this.
The only thing which has been bugging me for quite a long time now is the Swatch conflict popup.
Even though I'm using:
app.userInteractionLevel = UserInteractionLevel.DONTDISPLAYALERTS;
I still get these alerts.
That's why I was trying out the importFile() function, hoping to avoid that popup.