Push-Nachrichten von MacTechNews.de
Würden Sie gerne aktuelle Nachrichten aus der Apple-Welt direkt über Push-Nachrichten erhalten?
Forum>Software>jpg-Versand per Automator/Apple Script

jpg-Versand per Automator/Apple Script

jewi
jewi24.01.0811:47
Hallo,

da ich oft mehrere oder einzelne jpgs versenden muss wollte ich mir hierzu ein Hilfstool erstellen (Automator/Apple Script), was wie folgt ablaufen soll.

Markierte Datei im Finder kopieren (Zwischenablage)
Mail öffnen
in Betreff kopieren
in Mail-Anhang kopieren

fertig^^

kann mir da jemand nen tipp geben, wie ich das am besten erstelle? automator ist mir nicht so ganz schlüssig.

danke schonmal für antworten
0

Kommentare

_mäuschen
_mäuschen24.01.0812:00

Das wäre ein Anfang Using AppleScript to send an email with an attachment
0
jewi
jewi24.01.0812:05
da google ich die ganze zeit und find nix.... argl
0
jewi
jewi24.01.0812:18
das funzt aber leider nicht
0
Wowbagger24.01.0812:55
Für so was Einfaches würde ich, wenn Du noch keine Erfahrung mit AppleScript hast, Automator verwenden.

Die Aktionen "Ausgewählte Finder-Objekte abfragen" und "Neue Email" sollten ausreichen.
0
jewi
jewi24.01.0813:01
hm... schonmal ein anfang.
aber auch nichts anderes als das jpg auf mail zu schieben.
er sollte ja auch den dateinamen in betreff schreiben, weil wir das alles protokollieren müssen
0
_mäuschen
_mäuschen24.01.0813:16


set theName to "Empfänger Name"

set theAddress to "EMPÄNGERaddress@DOMAIN"

set theSender to "ABSENDERaddress@DOMAIN"

set theBody to return & return & "New picture" & space & (current date)

set fileAttachThis to choose file with multiple selections allowed

set theSubject to name of (info for item 1 of fileAttachThis)

tell application "Mail"
-- Properties can be specified in a record when creating the message or
-- afterwards by setting individual property values.
set newMessage to make new outgoing message with properties {subject:theSubject, content:theBody & return & return}
tell newMessage
-- Default is false. Determines whether the compose window will
-- show on the screen or whether it will happen in the background.
set visible to false
set sender to theSender
make new to recipient at end of to recipients with properties {name:theName, address:theAddress}

tell content
repeat with aFile in fileAttachThis
make new attachment ¬
with properties {file name:aFile} ¬
at before the first word of the ¬
first paragraph
end repeat

end tell
end tell
-- Bring the new compose window to the foreground, in all its glory
activate
send newMessage
end tell


0
söd knöd24.01.0813:26
Hallo,

wenn im betreff der komplette Pfad der Datei stehen darf kann man es mit dem Automator in Leopard durch eine Variable lösen.
0
jewi
jewi24.01.0813:27
hab aber 10.4
0
söd knöd24.01.0813:35
jewi
hab aber 10.4

Wenn ihr auch mit so einem komplett veraltetet System arbeitet , kan ich euch nicht helfen . Nein, Spass bei Seite, mit dem Automator von 10.4 wüsste ich jetzt keine Lösung als halt teilweise AppleScript mit einzubauen, aber da ist _mäuschen wohl der besser Ansprechpartner
0
jewi
jewi31.01.0811:53
Hallo,

ich versuche nun was anderes.
Wir müssen jede Mail ausdrucken und ablegen. Kann man das automatisieren, dass jede mail an eine bestimmte adresse ausgedruckt wird?

grüße
0
aikonch31.01.0812:01
**Offtopic**
Bitte wie?!? Jede Mail ausdrucken....willkommen im 21 Jahrhundert.... :sick:
**Offtopic**

Evt. würde sich der Nebel etwas lüften wenn Du genauer beschreiben würdest was Du denn machen willst....Wieso verwaltest Du die Bilder im Finder und nicht in iPhoto wäre die erste Frage und weitergehen würde es mit in welchem "Format" sollen die Dateinamen im Titel stehen....
0
jewi
jewi31.01.0812:07
wir müssen wg. abrechnungen usw. die gesendeten mails an kunden ausdrucken, so dass das nachgewiesen werden kann. Die Bilder braucht keiner... es geht nur um den Arbeitsablauf. So brauche ich von jeder gesendeten Mail an Kunden die erste Seite als Ausdruck. Es lebe das Formularwesen.

Ich schicke eine Mail an Kunden xy (was am Tag dutzende Mal passiert). Ich will eine Regel in Mail einführen, wenn eine Mail an Kunden xy gesendet wird, Mail ein AppleScript nutzt um das Ding auszudrucken
0
jewi
jewi31.01.0812:12
aikonch
**Offtopic**
Bitte wie?!? Jede Mail ausdrucken....willkommen im 21 Jahrhundert.... :sick:
**Offtopic**

**Offtopic**
Willkommen im Formularwesen des 21. Jahrhundert.... :sick:
**Offtopic**
0
_mäuschen
_mäuschen01.02.0817:16

Diesen Script als Folder Action an den 'Messages' Ordner
in Deinem 'Sent Messages.imapmbox' Ordner hängen

property _theAddress : "" -- the recipient
property _theSender : "" -- account address
property _theSenderName : "" -- account name
property _theDest : "Trash"

on adding folder items to this_folder after receiving these_items
 tell application "System Events" to tell application "Mail"
  repeat
   if background activity count is 0 then exit repeat
   delay 1
  end repeat
 end tell
 tell application "Mail"
  activate
  repeat with thisMessage in these_items
   try
    set thisMessage to ¬
     (first message of mailbox "Sent") of ¬
     account _theSenderName
    set theName to address of recipient of thisMessage
    set theAccount to account of mailbox of thisMessage
    if (theName contains _theAddress) and ¬
     (theName contains _theSender) then
     tell application "System Events" to tell process "Mail"
      keystroke "p" using command down
      delay 1
      tell window 1
       keystroke tab
       keystroke tab
       keystroke tab
       keystroke "1"
       keystroke tab
       keystroke "1"
       keystroke tab
       delay 1
       keystroke return
      end tell
     end tell
     move thisMessage to mailbox _theDest of theAccount
    end if
   end try
  end repeat
 end tell
end adding folder items to
0
jewi
jewi01.02.0817:18
o.O.... sagenhaft...


MERCI!!!

0
_mäuschen
_mäuschen01.02.0817:18

Ja. Und wichtig ist, dass Du Dich selbst als Blindkopie einträgst

0
_mäuschen
_mäuschen01.02.0817:40

Oh, den Trash würd' ich noch ändern zu Archive oä oder auskommentieren
0
jewi
jewi01.02.0817:44
bei im Schnitt 72 Spam am Tag wäre das in der Tat ratsam
0

Kommentieren

Diese Diskussion ist bereits mehr als 3 Monate alt und kann daher nicht mehr kommentiert werden.