Skip to main content
ilya_ananyev
Participating Frequently
February 4, 2019
Answered

Import offline file / setting imported clip as offline

  • February 4, 2019
  • 4 replies
  • 976 views

Hello, I've got two questions, where you guys could help me with.

1. Following use case I need to implement: importing of a file, which probably does not exist yet. Could you suggest any proper solution for it?

What I've tried to use is: app.project.importFiles([audioFilePath], 1, app.project.getInsertionBin(), 0);

In case if audioFilePath is pointing to a not existing file, I receive an error "Unsupported format or damaged file". Another idea was just to create an offline file (similar to "new item..." -> "offline file...", but I couldn't find any function to do that. The last thing I've tried is to create a dummy file, import it and then change the path    item.changeMediaPath(newAudioPath, true); However I get "The importer reported a generic error" message. Any suggestion is welcome. Thanks in advance!

2. While trying to play with online/offline files I faced another bug (?). In the PProPanel if I click "Online all offline" or "Make selected items offline" I get error "Function currentChild.isOffline is undefined". My selected item is an existing mp3 file imported from FS.

This topic has been closed for replies.
Correct answer Bruce Bullis

The offline-handling API was new in 13.0.

4 replies

Bruce Bullis
Legend
February 4, 2019

1. Following use case I need to implement: importing of a file, which probably does not exist yet. Could you suggest any proper solution for it?

The current APIs only support importing actual, existent files.

In the PProPanel if I click "Online all offline" or "Make selected items offline" I get error "Function currentChild.isOffline is undefined".

What version of PPro are you running?

ilya_ananyev
Participating Frequently
February 5, 2019

What version of PPro are you running?

PPro 12.1.2x69

Bruce Bullis
Bruce BullisCorrect answer
Legend
February 5, 2019

The offline-handling API was new in 13.0.