Skip to main content
lfcorullon13651490
Legend
December 10, 2024
Question

[SCRIPTING] Bridge is not waiting the end of a function to start another

  • December 10, 2024
  • 1 reply
  • 557 views

Hello, there. Let's see if anybody can help...

I have a Bridge script that renames and move the visibleThumbnails to new folders.

Easy like this: I have 15 visibleThumbnails, then the script will creates 15 folders and move each visibleThumbnail to its own folder.

BUT...

I need another function to run over the new created folders.

This another function is being called after the loop that create the folders.

But this another function never runs unless I put an alert at its beginning.

 

Any help?

This topic has been closed for replies.

1 reply

Stephen Marsh
Community Expert
Community Expert
December 10, 2024

@lfcorullon13651490 – Perhaps if you shared the code...

lfcorullon13651490
Legend
December 10, 2024

I don't think it'll help. My scenario is very particular.

I have three functions:

 

function rotate() {

/*compare the width and height and rotate vertical image counterclockwise*/

}

function move() {

/*it creates a folder and move each thumbnail to one new folder.

if 15 thumbnails, then 15 folders will be created, numbered, to move each thumb to its folder*/

}

function rename() {

/*rename some files that are previously moved to a new folder*/

}

 

And I think this is the problem. Bridge doesn't wait the folder creation and the files to be moved to start the next function. When it starts, no folders are created yet.

Stephen Marsh
Community Expert
Community Expert
December 11, 2024
quote

I don't think it'll help.


By @lfcorullon13651490

 

You have a problem with the code, however, you don't think that it will help to post the code in full. Not sure what can be done then.