The following script is close but includes every image I've selected on every email. How can I modify this script to give me just one image per email?
Code: Select all
if (get("CountSelected")<1){end 1, "Please select at least one file first!<crlf>Script quits.";}
//"SelectedItemsNames", [separator=CRLF], [pane=a]
$filelist = get("SelectedItemsNames");
//foreach($variable, listoftokens, [separator=|])
foreach($MyNewVariable, $filelist, "<crlf>")
{
// msg $MyNewVariable,1;
//Attach to Thunderbird
//Get item's path and names
$items=chr(39).get("SelectedItemsPathNames",",").chr(39);
//Get item's names
$itemnames=chr(39).get("SelectedItemsNames",", ").chr(39);
//Get item's Exif
$itemexif=chr(39) . "Camera: " . property("Manufacturer", ) . " " . property("CameraModel", ) . " | " . "Exposure: " . property("ExposureTime", ) . " sec. | " . "f/" . property("Aperture", ) . " | ISO: " . property("ISOspeed", ) . chr(39);
//Insert values into Thunderbird syntax
$TB_Syntax= chr(34)."subject=$itemnames,body=$itemexif,attachment=$items".chr(34);
//Attach selected files to thunderbird's compose window
run """c:\Program Files (x86)\Mozilla Thunderbird_v6\Thunderbird.exe"" -compose $TB_Syntax";Thanks.
~Nick
XYplorer Beta Club