• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Is it possible to retrieve photo array of kPreviousImport "collection"

New Here ,
Oct 02, 2019 Oct 02, 2019

Copy link to clipboard

Copied

Hi everyone, this thread is a copy pasta of this thread i  wrote on this forum : https://feedback.photoshop.com/photoshop_family/topics/sdk-lightroom-is-it-possible-to-retrieve-phot...

 

Il don't know which forum is the good one for this question.

 

I am trying to make a plugin in order to apply a batch treatment on photos that are actually viewed in lightroom depending on the current view in the library tab.

 

So i wanted to use the catalog:getActiveSources() function in order to get the right folder or collection and get photos in them.

 

This function work very well with directory or classic collections, but when the current view in Lightroom is the Previous import one, the function returns to me : "previous_import" that is the value of the kPreviousImport constant. 

 

Is there any possibilities to retreive photos contained in this "collection" ?

We can't reach it with the different collection functions : catalog:getChildCollections(), catalog:getChildCollectionSets()

I even tried to find this "collection" using a loop and catalog:getCollectionByLocalIdentifier() function but with no result 😞


The documentation of getActiveSources say :"

catalog:getActiveSources() 
Retrieves currently viewed collections, collection sets, or folders.

First supported in version 3.0 of the Lightroom SDK.

Return value(table) Array of the currently viewed objects as LrCollectionLrCollectionSetLrPublishedCollectionLrPublishedCollectionSetLrFolder or one of the string constants defined in these LrCatalog properties:

  • kAllPhotos
  • kQuickCollectionIdentifier
  • kPreviousImport
  • kTemporaryImages
  • kLastCatalogExport

 

Thank you for your help

TOPICS
SDK

Views

278

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Oct 04, 2019 Oct 04, 2019

Copy link to clipboard

Copied

LATEST

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines