var fileList = app.document.selections;
  for(var i=0; i<fileList.length; i++){
  myBTalk(fileList[i].path);
  }
function myBTalk(filename){
  var scriptcode = 'var myImage = app.activeDocument.placedItems.add();';
  scriptcode += 'myImage.file = new File("'+filename+'")';
  $.writeln(scriptcode);
  var btObj = new BridgeTalk;
  btObj.body = scriptcode;
  btObj.target = "illustrator-13";
  btObj.send();
  }
var fileList = app.document.selections;
  for(var i=0; i<fileList.length; i++){
  myBTalk(fileList[i].path);
  }
function myBTalk(filename){
  var scriptcode = 'var myImage = app.activeDocument.placedItems.add();';
  scriptcode += 'myImage.file = new File("'+filename+'");';
  scriptcode += 'myImage.embed()';
  $.writeln(scriptcode);
  var btObj = new BridgeTalk;
  btObj.body = scriptcode;
  btObj.target = "illustrator-13";
  btObj.send();
  }
var PSCS3 = "/Applications/Adobe Photoshop CS3/Adobe Photoshop CS3.app";
  var fileList = app.document.selections;
  for(var i=0; i<fileList.length; i++){
  myBTalk(fileList[i].path);
  fileList[i].openWith(PSCS3);
  }
function myBTalk(filename){
  var scriptcode = 'var myImage = app.activeDocument.placedItems.add();';
  scriptcode += 'myImage.file = new File("'+filename+'")';
  $.writeln(scriptcode);
  var btObj = new BridgeTalk;
  btObj.body = scriptcode;
  btObj.target = "illustrator-13";
  btObj.send();
  }