on reparer cha”ne
  global scriptFindString
  put cha”ne into scriptFindString
  if the script of this stack contains cha”ne then edit the script of this stack
  push cd
  repeat with x = 1 to the number of bgs
    go to bg x
    if the script of this bg contains cha”ne then edit the script of this bg
    if the number of bg parts > 0 then
      repeat with y = 1 to the number of bg parts
        if the script of bg part y contains cha”ne then edit the script of bg part y
      end repeat
    end if
  end repeat
  repeat with x = 1 to the number of cds
    go to cd x
    if the script of this cd contains cha”ne then edit the script of this cd
    if the number of cd parts > 0 then
      repeat with y = 1 to the number of cd parts
        if the script of cd part y contains cha”ne then edit the script of cd part y
      end repeat
    end if
  end repeat
  pop cd
end reparer

on reparer cha”neRecherchee
  hide msg box
  ---------------------------------------------------------------------------
  if cha”neRecherchee is empty then
    ask "Cha”ne ˆ rechercher dans tous les scripts ?" with "on"
    if it is not empty then put it into cetteCha”ne else exit reparer
  else
    put cha”neRecherchee into cetteCha”ne
  end if
  ---------------------------------------------------------------------------
  put liste("piles") into allStacks
  set itemDelimiter to tab
  push cd
  repeat with x = 1 to the number of lines of allStacks
    if item 1 of line x of allStacks is "scripts" then next repeat -- TEMP
    go to stack item 2 of line x of allStacks
    set the cantModify of this stack to false
    fouillerScripts cetteCha”ne
    if the commandKey is down then
      pop cd
      exit reparer
    end if
  end repeat
  pop cd
  ---------------------------------------------------------------------------
end reparer