The stack "AllImages" contains one cd with 36 images
The substack "LeMagasin" contains 36 cds with one image in each cds
I need to set the text of image 1 of each cd of substack "Lemagasin" to the text of img n (n=1 to 36) of stack "AllImages"
This script dont work i have one error :
Error description: Chunk: no such object
I'm sur it is possible to do that more simple
Thank in advance for your help
Jean-Marc
Code: Select all
on ImpImDeOld
global MonStack,MagStack,LeStack,gDev
put empty into gDev
set the lockmessages to true
put "MagImagesEtRef" into LaCD
put the filename of this stack into MonStack
put "LeMagasin" into MagStack
answer file "Importer de :"
if it = empty then
exit ImpImDeOld
end if
put it into LeStack --•• i select the stack "AllImages"
open inv cd LaCD of stack leStack
put the num of images of cd LaCD of stack leStack into nb
repeat with i = 1 to nb
put the short name of img i of cd LaCD of stack LeStack into bufLeNom
put SansSuffixe(bufLeNom) into LaCDdest
put LaCDdest&return after gdev
--All ways return one error message : Chunk: no such object without comment
-- set the text of img 1 of cd LaCDdest of stack MagStack of stack MonStack to the text of img LeNom of cd LaCD of stack leStack
-- set the text of img 1 of cd LaCDdest of stack MagStack to the text of img LeNom of cd LaCD of stack leStack
put the text of img LeNom of cd LaCD of stack leStack into vTextIm
open stack MonStack
open cd LaCDdest of stack MagStack
set the text of img 1 of cd LaCDdest of stack MagStack to vTextIm
wait 2 milliseconds with messages
--•• All ways return one error message END
end repeat
set the lockmessages to false
end ImpImDeOld