Jump to content

Recommended Posts

Guest Beefteck
Posted (edited)

(not to much to say really...)

Basically I need a script that will send text entered in a text(input) box to my email (gmail) WHEN a button is pressed.

Thankyou for reading, :P

EDIT1:

OK THANK-YOU SO MUCH!!! I GOT IT TO WORK!!!

but, how would i make the text body be from text inputed into a text input box??? I am not to good with variables... here is the script that i would like to work with, thanks again.

CODE
#cs ----------------------------------------------------------------------------

AutoIt Version: 3.1.1.0

Author: myName

Script Function:

Template AutoIt script.

#ce ----------------------------------------------------------------------------

; Script Start - Add your code below here

$a = "smtp.gmail.com"

$b = "****@gmail.com"

$c = "***"

Emailx("****@gmail.com", "****@rcn.com", "Super Test", "THIS IS WHERE THE BODY TEXT GOES")

Func Emailx($d, $e, $f, $g)

$h = ObjCreate ("CDO.Message")

With $h

.Subject = $f

.Sender = $d

.From = $d

.To = $e

.TextBody = $g

;.AddAttachment ("C:\Documents and Settings\myname\Desktop\files\file.txt");needs full path- optional

EndWith

With $h.Configuration.Fields

.Item ("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2

.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserver") = $a

.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 465

.Item ("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1

.Item ("http://schemas.microsoft.com/cdo/configuration/sendusername") = $b

.Item ("http://schemas.microsoft.com/cdo/configuration/sendpassword") = $c

.Item ("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 90

.Item ("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = True

.Update

EndWith

$h.Send

Return

EndFunc;==>Emailx

-Beefteck

-Beefteck

Edited by Beefteck
Guest Beefteck
Posted

ok, when i get back to my house i will check them out. Thankyou

-Beefteck

Guest Beefteck
Posted

any help with that??? tried out my own set with variables, but well... didnt work... code at top for what i want to use to send to email, thanks

-Beefteck

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...