WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

Postie

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

Bulk Emailer


Keywords: bulk mail spam anti-spam address lists
I needed a cheap way to send the same email to a few hundred people (members of a club) and found that my ISP prevented me from sending more than about 15 emails at a time. No surprise here, of course. So I wrote a script to do the job by introducing a short delay (customizable) between each invocation of the sending routine, reading the addresses from a file. One thing led to another, with the resulting attached script.
; ClubMail version 1.00
; Author: Richard Briggs
; Company: Technology Direction Incorporated
; Copyright (c) 2003 Richard Briggs. All rights reserved.
; This script may be distributed freely for non-commercial use without payment of royalty.
; All commercial rights are reserved.
;
; This is a "bulk" email program designed for relatively small mailing lists.
; It's designed to get around the limitations imposed by many ISPs to prevent spammers
; from abusing their system. ClubMail introduces a short delay (customizable) between
; each separate send invocations. The optimum delay is up to the user -- but 3 seconds
; seems to work pretty well.
;
; If the delay is set to zero, in theory this script could become a spam propagator. 
; However, in that case the ISP limits should kick back in.

IntControl(72, 2, 0, 0, 0) ; Causes "cancel" clicks to CALL the cancel routine as a subroutine
AddExtender("WWPST34I.DLL")
AddExtender("wwint34i.dll")
	
	ClubMailVersion = "1.00 Build 1001"

; START TOP LEVEL CODE
	dbg="%param1%"
	IF dbg=="/DEBUG" THEN
	  Message("Club Mail - DEBUG mode","ClubMail is running in DEBUG Trace Mode now !" )
	  DebugTrace(@on,"ClubMailTrace.txt")
	ENDIF

	IF (dbg=="/HELP" || dbg=="/?") THEN
		line1="/DEBUG Starts ClubMail in Debug Mode"
		line2="/HELP Shows this Window"
		line3="/?    Shows this Window"

		InfoLine=StrCat(line1,@CRLF, line2, @CRLF, line3)
	
		Message("STARTNT - HELP",Infoline )
	ENDIF
   drop (dbg)

	GOSUB DefineFunctions		 ; Functions are almost at end of this script

	; Do some variable initializations...
	DebugClubMail = 0
	SimulateSending = 0

	ProfileFile = "ClubMail$$Profile.ini"

	host = "*INIT*"
	fromaddr = "*INIT*"
	userid = "*INIT*"
	password = "*INIT*"
	EmailAddressDir = "*INIT*"
	AddressFile = "*INIT*"
	AttachmentFile = "*INIT*"
	AttachmentDir = "*INIT*"
	port = "*INIT*"
	SendingDelay = "*INIT*"	   

	zzNormalCancel = 1
	zzCriticalCancel = 2



	GOSUB GetDefaultProfile
	IF iniShowSplashScreen == @TRUE THEN
		Message("SplashScreen", CreateInfoString (ClubMailVersion)	  )
	ENDIF
	
	SomethingToDo = @TRUE
	WHILE SomethingToDo
		UserCancel = @FALSE
		GOSUB DoMyDialog
	
		SWITCH ButtonPushed
			CASE 1 ; Send

					GOSUB VerifyAllData
					
					IF AllDataOK == @TRUE THEN

						GOSUB VerifyConnection

						IF ConnectionOK THEN
							IF Password == "" THEN
								password = AskPassword("Enter Login Password", "Please enter your account password.")
							ENDIF

							GOSUB ProcessAddressFile
							SomethingToDo = @FALSE
						ENDIF
					ELSE
						Message("Problem with parameters", ValidateMessage)
					ENDIF
				BREAK
	
			CASE 2 ; Cancel
					SomethingToDo = @FALSE
				BREAK
	
			CASE 3 ; Find Address file
					GOSUB GetAddressFile
				BREAK
	
			CASE 4 ; Find Attachment Directory
					GOSUB GetAttachmentDir
				BREAK
	
			CASE 5 ; Find Attachment file
					GOSUB GetAttachmentFile	
				BREAK
	
			CASE 6 ; Find Message Directory
					GOSUB GetMessageDir
				BREAK

			CASE 7 ; Find Message File
					GOSUB GetMessageFile	
				BREAK
	
			CASE 8 ; Select Profile
					GOSUB GetProfileName
				BREAK
	
			CASE 9 ; Update Profile
					GOSUB UpdateProfile
				BREAK
				
			CASE 10 ; Delete Current profile
					GOSUB DeleteProfile
				BREAK

			CASE 11 ; Help screen
					s = StrCat("General help...",@CRLF, @CRLF)
					s = StrCat(s, "The information that probably won't change between sessions is stored in profiles.",@CRLF)
					s = StrCat(s, "The values for the currently active profile are shown in the bottom half of the screen.",@CRLF)
					s = StrCat(s, "You can update the values, save them, etc. It's OK to have multiple profiles.",@CRLF, @CRLF)
					s = StrCat(s, "The info for each particular bulk email is entered above the thick line.", @CRLF,@CRLF)
					s = StrCat(s, "Basic approach to doing a bulk email with ClubMail program:", @CRLF)
					s = StrCat(s, "      Create and save a profile. This tells ClubMail about your email account.", @CRLF)
					s = StrCat(s, "      The profile also allows you to indicate a ""standard attachment"" that you", @CRLF)
					s = StrCat(s, "      will send with most bulk email messages.", @CRLF, @CRLF)
					s = StrCat(s, "      Enter the subject for your email, then type in the message itself.", @CRLF)
					s = StrCat(s, "      You can also specify a text file that contains a message by entering its", @CRLF)
					s = StrCat(s, "      name in the box labeled ""Message File""", @CRLF, @CRLF)
					s = StrCat(s, "      Select any profile options (such as simulate sending), and check the box if you", @CRLF)
					s = StrCat(s, "      want to send the attachment shown in the profile.", @CRLF, @CRLF)
					s = StrCat(s, "      Click ""Send Mail"" button to start processing.", @CRLF, @CRLF)
					s = StrCat(s, "The little buttons with a ""?"" on them have additional help about specific items.",@CRLF, @CRLF)
					s = StrCat(s, "The buttons labeled ""FIND"" open up file selection windows so you can find a particular file.",@CRLF)
					Message("Help", s )
					BREAK

			CASE 12 ; Info on Address File
					Message("Address File Info", CreateAddressFileInfoString ()	  )
					BREAK

			CASE 13 ; Info about password protection
					s = StrCat("This is the same password you use to access your email account.", @CRLF, @CRLF)
					s = StrCat(s,"If you leave the password blank, the program will prompt for it later.",@CRLF)
					s = StrCat(s, "If you enter a value here, it will be stored in the profile and used automatically.", @CRLF, @CRLF)
					s = StrCat(s, "However, please be aware that this password is NOT encrypted when stored in the", @CRLF)
					s = StrCat(s, "profile. If several people have access to this computer that might be a security risk.")
					Message("Password info", s)
					Drop(s)
					BREAK

			CASE 14 ; Info about profile options
					Message("Profile Options", CreateProfileOptionsString())
					BREAK

			CASE 15 ; Info about SMTP host
					s = StrCat("This is the address of the server you use to 'send' mail. It's the same address as used", @CRLF)
					s = StrCat(s, "in your email program. It will look something like this:", @CRLF)
					s = StrCat(s, "      smtp.kornet.co.kr", @CRLF)
					s = StrCat(s, "      relay.pair.com", @CRLF)
					s = StrCat(s, "      mail.earthlink.com", @CRLF, @CRLF)
					s = StrCat(s, "You probably will find this value in the 'settings' or 'options' section of your", @CRLF)
					s = StrCat(s, "regular email program. Look for ""SMTP Server"" --  Good luck!", @CRLF)
					Message("SMTP Host Info", s)
					BREAK

			CASE 16 ; Info about From address
					s = StrCat("This is your email return address. It's the same return address as used", @CRLF)
					s = StrCat(s, "in your email program. It will look something like:", @CRLF)
					s = StrCat(s, "      john@hotmail.com", @CRLF)
					Message("From address", s)
					BREAK

			CASE 17 ; Info about User ID
					s = StrCat("This is the same user ID you use to log in to your email service.", @CRLF)
					s = StrCat(s, "It will be a simple string of characters, such as ""john333"" or ""maryjones02""", @CRLF)
					Message("User ID", s)
					BREAK

			CASE ButtonPushed
				Message ("Processing Error", "Invalid button selection in dialog. Quitting...")
				BREAK
				EXIT
	
		ENDSWITCH
	ENDWHILE

EXIT

;=================================================================
;=================================================================
; START SUBROUTINE SECTION
;=================================================================
;=================================================================

:VerifyConnection
	; Simple test to see if internet connection is available
	; Future version -- try to establish connection if not already running
	; INPUT			None
	;
	; OUTPUT			ConnectionOK (boolean)
	;
		BoxOpen("Processing...", "Verifying internet connection.")
		IF SimulateSending == 0 THEN
			x=iPing("www.iltc.net",15)
			if x == 0
				m = StrCat("Program can't detect an internet connection." , @CRLF)
				m = StrCat(m, @CRLF, "Please make sure you are connected to the internet,")
				m = StrCat(m, @CRLF, "then try sending your message again.")
	  			Message("Connection Problem", m)
				ConnectionOK = @FALSE
			ELSE
	  			ConnectionOK = @TRUE
			ENDIF
		ELSE
			TimeDelay(2)
			ConnectionOK = @TRUE
		ENDIF
		BoxShut()

		DROP(x, m)
	RETURN
  
:GetDefaultProfile
		; This is very stupid and simple. We keep the user profiles in a 
		; private .ini file in the windows directory. See initialization for name.
		; No customization of directory or file name is possible in this version.
		; This particular routine is called when we can't find a user profile to load, thus
		; making sure there is a basic data stucture to manipulate.
		;
		; INPUT		ProfileFile 		= Simple name of the profile file (.ini) kept in WinDir
		;
		; OUTPUT	   ProfileFileName 	= Fully qualified file name of the profile
		;				SectionName			= Name of the "section" i.e., user profile, to use.
		;				ProfileOK			= Boolean indicating success/failure of this routine
		;				All the profile values (see ReadListOfProfiles)

		WinDir = DirWindows(0)
		ProfileFileName = strcat(WinDir, ProfileFile)

		IF !FileExist(ProfileFileName) THEN
			GOSUB CreateBasicProfileFile
		ENDIF

		IF FileExist(ProfileFileName) THEN
			; Check to see if file exists but without any profiles
			ProfileList = IniItemizePvt("", ProfileFileName)
			IF ProfileList == "" THEN
				GOSUB CreateBasicProfileFile
			ENDIF

		ENDIF
		; At this point there should always be something to read in the INI file

		SectionName	=	IniReadPvt("~~~LastProfile", "Profile",""  , ProfileFileName)

		GOSUB ReadUserProfile

		ProfileOK = @TRUE

		DROP(WinDir, ProfileList)
	RETURN

:GetProfileName
		; This is very stupid and simple. We keep the user profiles in a private .ini file in the windows directory.
		; No customization of directory or file name is possible in this version.
		; The user must select from the existing names. To create a new profile, the user types
		; in a new name on the form, then clicks "update"
		;
		; INPUT		SectionName 		= Current profile
		;			   ProfileFile 		= Simple name of the profile file (.ini) kept in WinDir
		;
		; OUTPUT		CancelLocation		= Keyword indicating this subroutine in case user cancels operation
		;				SectionName			= Either updated by the user or rolled-back to state at entry
		;				All the profile values (see ReadListOfProfiles)
		;
		CancelType = zzNormalCancel						; Get ready for possible cancellation
		OldSectionName = SectionName			; Save in case user cancels processing
		WinDir = DirWindows(0)
		ProfileFileName = strcat(WinDir, ProfileFile)

		IF !FileExist(ProfileFileName) THEN
			; Actually no way this should happen, but Mr. Murphy was here once before.
			GOSUB CreateBasicProfileFile
		ENDIF

		; At this point there should always be something to read in the INI file
		; Processing logic
		;		Display a list of profiles
		;		Ask user to select one
		GOSUB ReadListOfProfiles
		
		CancelLocation = "GetProfileName"
		SectionName = AskItemList("Select Profile to load", ProfileList, @TAB, @UNSORTED, @SINGLE)
		IF UserCancel == @TRUE THEN
			SectionName = OldSectionName
		ELSE
			GOSUB ReadUserProfile
		ENDIF
	RETURN

:ReadListOfProfiles
		ProfileList = IniItemizePvt("", ProfileFileName)
		; We want to delete the system section "~~~LastProfile" from the list

		tempProfileList = ItemSort(ProfileList, @TAB )              ; initialize listbox with sorted list
		x = ItemLocate("~~~LastProfile", tempProfileList, @TAB)
		IF x > 0 THEN
			ProfileList = ItemRemove(x, tempProfileList, @TAB)
		ENDIF

	RETURN

:ReadUserProfile
		; IniReadPvt(Profile Section, Key Name, Default Value, INI file name)
		Host 					=	IniReadPvt(SectionName, "host", "" , ProfileFileName)
		FromAddr 			=	IniReadPvt(SectionName, "FromAddr", "", ProfileFileName)
		UserID 				=	IniReadPvt(SectionName, "UserID", "", ProfileFileName)
		Password 			=	IniReadPvt(SectionName, "Password","", ProfileFileName)

		AddressFile			=	IniReadPvt(SectionName, "AddressFile",""  , ProfileFileName)
		SendAttachment		=	IniReadPvt(SectionName, "SendAttachment", "0" , ProfileFileName)
		AttachmentDir		=	IniReadPvt(SectionName, "AttachmentDir", "" , ProfileFileName)
		AttachmentFile		=	IniReadPvt(SectionName, "AttachmentFile", "" , ProfileFileName)
		MessageDir			=	IniReadPvt(SectionName, "MessageDir", "" , ProfileFileName)
		MessageFile			=	IniReadPvt(SectionName, "MessageFile", "" , ProfileFileName)

		Port 					=	IniReadPvt(SectionName, Port, "", ProfileFileName)
		SendingDelay 		=	IniReadPvt(SectionName, "SendingDelay" , 10, ProfileFileName)
		DebugClubMail 		=	IniReadPvt(SectionName, "DebugClubMail" , 0, ProfileFileName)
		SimulateSending		=	IniReadPvt(SectionName, "SimulateSending" , 0, ProfileFileName)
		ProcessAddressErrors	=	IniReadPvt(SectionName, "ProcessAddressErrors" , 0, ProfileFileName)
		iniShowSplashScreen	=	IniReadPvt(SectionName, "ShowSplashScreen" , 0, ProfileFileName)

	RETURN

:DeleteProfile
		; IniDeletePvt (section, keyname, filename)

		CancelType = zzNormalCancel
		ProfileWarning1 = StrCat("You are about to DELETE profile: " , SectionName)
		ProfileWarning2 = "This change takes place immediately. There is no undo function."
		GOSUB DoUpdateConfirm

		IF ButtonPushed == 1 THEN
			IniDeletePvt (SectionName, @WHOLESECTION, ProfileFileName)
			Message("Advisory", "Profile deleted.")
			GOSUB GetProfileName
		ELSE
			Message("Advisory", "Nothing has changed.")
		ENDIF
		

   RETURN

:UpdateProfile
		CancelType = zzNormalCancel
		ProfileWarning1 = StrCat("You are about to update profile: " , SectionName)
		ProfileWarning2 = "This change takes place immediately. There is no undo function."
		GOSUB DoUpdateConfirm

		IF ButtonPushed == 1 THEN
				; IniWritePvt(section, keyname, data, filename)
				; Tell system to load this profile next time we start
				IniWritePvt("~~~LastProfile","Profile", SectionName, ProfileFileName)

				IniWritePvt(SectionName, "Host" , host, ProfileFileName)
				IniWritePvt(SectionName, "FromAddr", fromaddr, ProfileFileName)
				IniWritePvt(SectionName, "UserID", userid , ProfileFileName)
				IniWritePvt(SectionName, "Password", password , ProfileFileName)

				IniWritePvt(SectionName, "AddressFile", AddressFile , ProfileFileName)
				IniWritePvt(SectionName, "SendAttachment", SendAttachment , ProfileFileName)
				IniWritePvt(SectionName, "AttachmentDir", AttachmentDir , ProfileFileName)
				IniWritePvt(SectionName, "AttachmentFile", AttachmentFile , ProfileFileName)
				IniWritePvt(SectionName, "MessageDir", MessageDir , ProfileFileName)
				IniWritePvt(SectionName, "MessageFile", MessageFile , ProfileFileName)

				IniWritePvt(SectionName, "Port", "",  ProfileFileName)
				IniWritePvt(SectionName, "SendingDelay", SendingDelay , ProfileFileName)

				IniWritePvt(SectionName, "DebugClubMail" , DebugClubMail, ProfileFileName)
				IniWritePvt(SectionName, "SimulateSending" , SimulateSending, ProfileFileName)
				IniWritePvt(SectionName, "ProcessAddressErrors" , ProcessAddressErrors, ProfileFileName)
				IniWritePvt(SectionName, "ShowSplashScreen" , iniShowSplashScreen, ProfileFileName)
				IniWritePvt("", "", "", ProfileFileName)

				Message("Advisory", "Profile updated.")
		ELSE
			message("Advisory", "Nothing has changed.")
		ENDIF
	RETURN

:CreateBasicProfileFile
		; Generally this will happen the first time the program is run, or after user deletes the ini file
		handle = FileOpen(ProfileFileName, "WRITE")
		IF handle == 0 THEN
			Message("Fatal Error", "Could not initialize profile file. Fatal error.")
			EXIT
		ELSE
			FileClose(handle)
		ENDIF
		
		;IniWritePvt(section, keyname, data, filename)
		IniWritePvt("~~~LastProfile","Profile", "Default", ProfileFileName)

		IniWritePvt("Default", "Host" , "*INIT*", ProfileFileName)
		IniWritePvt("Default", "FromAddr", "*INIT*", ProfileFileName)
		IniWritePvt("Default", "UserID", "*INIT*" , ProfileFileName)
		IniWritePvt("Default", "Password", "" , ProfileFileName)
		IniWritePvt("Default", "AddressFile", "*INIT*" , ProfileFileName)
		IniWritePvt("Default", "SendAttachment", "0" , ProfileFileName)
		IniWritePvt("Default", "AttachmentDir", "*INIT*" , ProfileFileName)
		IniWritePvt("Default", "AttachmentFile", "*INIT*" , ProfileFileName)
		IniWritePvt("Default", "MessageDir", "*INIT*" , ProfileFileName)
		IniWritePvt("Default", "MessageFile", "*INIT*" , ProfileFileName)
		IniWritePvt("Default", "Port", "", ProfileFileName)
		IniWritePvt("Default", "SendingDelay", "5" , ProfileFileName)
		IniWritePvt("Default", "DebugClubMail" , "0", ProfileFileName)
		IniWritePvt("Default", "SimulateSending" , "0", ProfileFileName)
		IniWritePvt("Default", "ProcessAddressErrors" , "0", ProfileFileName)
		IniWritePvt("Default", "ShowSplashScreen" , 1, ProfileFileName)
		IniWritePvt("", "", "", ProfileFileName)
	RETURN



:GetAddressFile
		CancelType = zzNormalCancel						; Get ready for possible cancellation
		OldAddressFile = AddressFile
		IF AddressFile == "" THEN
			AddressFile="AddressFile.txt"
		ENDIF
		types="All Files|*.*|Text Files|*.txt|"
		CancelLocation = "GetAddressFile"
		AddressFile=AskFileName("Select the file containing the list of email addresses", "C:\", types, AddressFile, 1)
		IF UserCancel == @TRUE THEN
			AddressFile = OldAddressFile
		ENDIF
		IF UserCancel == @TRUE THEN
			AddressFile = OldAddressFile
		ENDIF
	RETURN

:GetMessageDir
		CancelType = zzNormalCancel						; Get ready for possible cancellation
		OldMessageDir = MessageDir
		; AskDirectory(prompt, browse-root, start-dir, confirm-prompt, flags)
		prompt = "Select default directory for body of email message"	 
		CancelLocation = "GetMessageDir"
		MessageDir = AskDirectory(prompt, "", "", "", 0)
		IF UserCancel == @TRUE THEN
			MessageDir = OldMessageDir
		ENDIF
	RETURN

:GetMessageFile
		CancelType = zzNormalCancel						; Get ready for possible cancellation
		OldMessageFile = MessageFile
		IF MessageFile == "" THEN
			MessageFile
		MessageFile=""
		IF !IsDefined(MessageDir) THEN
			 MessageDir = ""
		ENDIF
		types="All Files|*.*|Text Files|*.txt|"
		MessageFile=AskFileName("Select the Message File", MessageDir, types, "Message.txt", 1)
	RETURN

:GetAttachmentDir
		CancelType = zzNormalCancel						; Get ready for possible cancellation
		OldAttachmentDir = AttachmentDir
		; AskDirectory(prompt, browse-root, start-dir, confirm-prompt, flags)
		prompt = "Select default directory for attachments"
		CancelLocation = "GetAttachmentDir"
		AttachmentDir = AskDirectory(prompt, "", "", "", 0)
		IF UserCancel == @TRUE THEN
			AttachmentDir = OldAttachmentDir
		ENDIF
	RETURN

:GetAttachmentFile
		CancelType = zzNormalCancel						; Get ready for possible cancellation
		OldAttachmentFile = AttachmentFile
		IF AttachmentFile == "" THEN
				AttachmentFile = "Attach.doc"
		ENDIF
		; AskFileName(title, directory, filetypes, default filename, flag)
		IF !IsDefined(AttachmentDir) THEN
			 AttachmentDir = ""
		ENDIF
		types="All Files|*.*|Text Files|*.txt|"
		CancelLocation = "GetAttachmentFile"
		AttachmentFile=AskFileName("Select the Attachment File", AttachmentDir, types, AttachmentFile, 1)	 
		IF UserCancel == @TRUE THEN
			AttachmentFile = OldAttachmentFile
		ENDIF
	RETURN


:VerifyAllData
		ValidateMessage = ""
		AllDataOK = @TRUE

		IF Host  == "" THEN 
			AllDataOK = @FALSE
			ValidateMessage = strcat(ValidateMessage, "SMTP host is not valid.", @CRLF)
		ENDIF

		IF isNumber(SendingDelay) THEN
			IF SendingDelay < 1 THEN
				ValidateMessage = strcat(ValidateMessage, "Sending delay must be positive.", @CRLF)
			ENDIF
		ENDIF

	  	IF SendingDelay > 60 THEN
			Message("Information", "Sending delay is pretty big!")
		ENDIF


		IF Subject == "" THEN
			AllDataOK = @FALSE
			ValidateMessage = strcat(ValidateMessage, "Email message does not have a subject.", @CRLF)
		ENDIF

		IF FromAddr == "" THEN 
			AllDataOK = @FALSE
			ValidateMessage = strcat(ValidateMessage, "'From' Email address is not valid.", @CRLF)
		ENDIF

		IF UserID == "" THEN 
			AllDataOK = @FALSE
			ValidateMessage = strcat(ValidateMessage, "User ID is not valid.", @CRLF)
		ENDIF

		IF !FileExist(AddressFile) THEN 
			AllDataOK = @False
			ValidateMessage = strcat(ValidateMessage, "Address file not found.", @CRLF)
		ENDIF
		IF SendAttachment == 1 THEN
			IF !FileExist(AttachmentFile) THEN 
				AllDataOK = @False
				ValidateMessage = strcat(ValidateMessage, "Attachment not found.", @CRLF)
			ENDIF
		ENDIF

		IF Port == "*INIT*" THEN 
			AllDataOK = @FALSE
			ValidateMessage = strcat(ValidateMessage, "Port number is not valid.", @CRLF)
		ENDIF

		IF SendingDelay == "*INIT*" THEN 
			AllDataOK = @FALSE
			ValidateMessage = strcat(ValidateMessage, "Sending delay is not valid.", @CRLF)
		ENDIF
		
	RETURN


:ProcessAddressFile
		cclist = ""
		bcclist = ""
		flags = ""

		MessagesSent = 0
		MessagesSkipped = 0
		MessageErrors = 0

		; Concatenate the edit box and the message file into "ComboMessageFile"
		TempMessageFile = FileCreateTemp("tmp")
		handleTempMessageFile = FileOpen(TempMessageFile,"WRITE")
		FileWrite(handleTempMessageFile, MessageText)
		FileClose(handleTempMessageFile)
		
		ComboMessageFile=FileCreateTemp("tmp")
		IF MessageFile <> "" THEN
			FileCopy(StrCat(TempMessageFile, @TAB, MessageFile), ComboMessageFile, @FALSE)
		ELSE
			ComboMessageFile = TempMessageFile
		ENDIF
		
		IF DebugClubMail == 1 THEN
			msg = StrCat("TempMessageFile= ", TempMessageFile, @CRLF)
			msg = StrCat(msg, "ComboMessageFile= ", ComboMessageFile, @CRLF)
			msg = StrCat(msg, "Ready to send messages.")
			message ("Running", msg)
		ENDIF

		InitializeText = StrCat("Press CTRL-Break to stop processing", @CRLF)
		IF SendAttachment == @TRUE THEN
			AttachmentFileToSend = AttachmentFile
			IF AttachmentFile == "" THEN
				InitializeText = StrCat(InitializeText, "Initializing..." , @CRLF,  "Note: An attachment file was not specified.")
			ELSE
				InitializeText = StrCat(InitializeText, "Initializing..." , @CRLF,  "The attachment file will be sent with the message.")
			ENDIF
		ELSE	
			AttachmentFileToSend = ""
			IF AttachmentFile == "" THEN
				InitializeText = StrCat(InitializeText, "Initializing...") 
			ELSE
				InitializeText = StrCat(InitializeText, "Initializing..." , @CRLF,  "The attachment file will NOT be sent with the message.")
			ENDIF

		ENDIF

		BoxOpen("Mailing Status", InitializeText)
		TimeDelay(5)

		dsecs = INT(SendingDelay)  ; Converts string delay into integer delay (still in seconds)
		IF dsecs > 59 THEN
			dmins = int(floor(dsecs / 60 ))
			dsecs = dsecs - ( dmins * 60 )
			str_dmins = strFixCharsL(dmins, "0", 2)
			str_dsecs = strFixCharsL(dsecs, "0", 2)
		ELSE
			str_dmins = "00"
			str_dsecs = strFixCharsL(dsecs, "0", 2)
		ENDIF

		DelayDelta = strCat("0000:00:00:00:", str_dmins, ":", str_dsecs)

		GOSUB ProcessAddressFile_WorkHorse

		IF DebugClubMail == 1 THEN
			message ("Running", "All messages sent... I hope.")
		ENDIF

		BoxShut()

		BoxMsg = Strcat(MessagesSent, " messages sent successfully.", @CRLF)
		BoxMsg = strcat(BoxMsg, MessageErrors, " messages not sent due to errors.", @CRLF)
		IF ProcessAddressErrors == @TRUE THEN
				BoxMsg = StrCat(BoxMsg, @CRLF, "'Good' email addresses stored in: ", nameAddressFileGood, @CRLF)
				BoxMsg = StrCat(BoxMsg, @CRLF, "'Bad' email addresses stored in: ", nameAddressFileBad, @CRLF)
		ENDIF

		Message("Final processing results:", BoxMsg)


	RETURN

:ProcessAddressFile_WorkHorse

		IF ProcessAddressErrors == @TRUE THEN
			IntControl (81, 0, 0, 0, 0)		 ; Randomize the random number generator
			Prefix =  StrFixLeft(RANDOM(9999999),"0",9)
			t1 = StrScan(AddressFile, "\", StrLen(AddressFile), @BACKSCAN)
			s1 = StrSub(AddressFile, t1+1, -1)  ; This is the file name
			s2 = StrSub(AddressFile, 1, t1)	 ; This is the path

			nameAddressFileGood = StrCat(s2, Prefix, "-Good-", s1)
			nameAddressFileBad = StrCat(s2, Prefix, "-Bad-", s1)

			handleAddressFile_Good = FileOpen(nameAddressFileGood, "WRITE")
			handleAddressFile_Bad = FileOpen(nameAddressFileBad, "WRITE")
		ENDIF

		handleAddressFile = FileOpen(AddressFile, "READ")
		while @TRUE             ; Loop till break do us end

			
			EmailAddressTO = FileRead(handleAddressFile)
			If EmailAddressTO == "*EOF*" Then 
				BREAK
			ELSE
				tolist = ""
				EmailAddressTO = strTrim(EmailAddressTo)	
				semi = strIndex(EmailAddressTO, ";", 1, @FWDSCAN)

				IF semi == 0 THEN
					;Treat this as a plain line with address
					tolist = strTrim(EmailAddressTO)
				ENDIF

				IF semi == 1 THEN
					; This is a comment line or bad email address
					tolist = ""
				ENDIF

				IF semi > 1 THEN
					; We found a person's name or some other comment. Strip it off.
					tolist = strTrim(strSub(EmailAddressTO, 1, semi - 1))
				ENDIF
			ENDIF

			IF DebugClubMail == @TRUE THEN
				Message("Variable tolist value", tolist)
			ENDIF

			; We want to ignore blank and obviously incorrect address lines
			IF EmailAddressOK(tolist)== @FALSE THEN
				FileWrite(handleAddressFile_Bad, EmailAddressTO)
			ELSE
				; Put up the progress box
				IF SimulateSending == @FALSE THEN
					BoxMsg = StrCat("To stop processing, press CTRL-Break. Then click [OK].", @CRLF)
					BoxMsg = Strcat(BoxMsg, MessagesSent, " messages sent successfully.", @CRLF)
					BoxMsg = strcat(BoxMsg, MessageErrors, " messages not sent due to errors.", @CRLF, @CRLF)
					BoxMsg = strcat(BoxMsg, "Now trying to send message to: <", EmailAddressTO, ">", @CRLF)
				ELSE
					BoxMsg = StrCat("To stop processing, press CTRL-Break. Then click [OK].", @CRLF)
					BoxMsg = StrCat(BoxMsg, MessagesSent, " messages sent (simulation mode)", @CRLF, @CRLF)
				   BoxMsg = strcat(BoxMsg,"Simulation - now sending message to person:  <", EmailAddressTO, ">", @CRLF)
				   BoxMsg = strcat(BoxMsg,"      using email address: <", tolist, ">")
				ENDIF
				BoxText(BoxMsg)
	
				; ACTUALLY SEND THE EMAIL MESSAGE
				IF tolist <> "" THEN
					GOSUB SendEMail
				ENDIF
	
				SWITCH SendStatus

					CASE -9999
				   		; This is simulation mode
							MessagesSent = MessagesSent + 1
							BoxMsg = StrCat("To stop processing, press CTRL-Break. Then click [OK].", @CRLF)
							BoxMsg = StrCat(BoxMsg, MessagesSent, " messages sent (simulation mode)", @CRLF)
						   BoxMsg = strcat(BoxMsg,"Simulation - last message sent to:  <", EmailAddressTO, ">")
							BREAK

					CASE  0 
							; This is "real" sending with an error return
							MessageErrors = MessageErrors + 1
							BoxMsg = StrCat("To stop processing, press CTRL-Break. Then click [OK].", @CRLF)
							BoxMsg = Strcat(BoxMsg, MessagesSent, " messages sent successfully.", @CRLF)
							BoxMsg = strcat(BoxMsg, MessageErrors, " messages not sent due to errors.", @CRLF)
							BoxMsg = strcat(BoxMsg, "Error! Last message NOT sent to: <", EmailAddressTO, ">", @CRLF)

							IF ProcessAddressErrors == @TRUE THEN
								; Add this recipient to the failed email address file
								FileWrite(handleAddressFile_Bad, EmailAddressTO)
							ENDIF

							BREAK

					CASE SendStatus
							; This is "real" sending with a success code
							MessagesSent = MessagesSent + 1
							BoxMsg = StrCat("Press CTRL-Break to stop processing", @CRLF)
							BoxMsg = Strcat(BoxMsg, MessagesSent, " messages sent successfully.", @CRLF)
							BoxMsg = strcat(BoxMsg, MessageErrors, " messages not sent due to errors.", @CRLF)
							BoxMsg = strcat(BoxMsg, "Success. Last message sent to: <", EmailAddressTO, ">", @CRLF)

							IF ProcessAddressErrors == @TRUE THEN
								; Add this recipient to the successful address file
								FileWrite(handleAddressFile_Good, EmailAddressTO)
							ENDIF

							BREAK

				ENDSWITCH
				
	
				BoxMsg = StrCat(BoxMsg, @CRLF, @CRLF, "Delaying ", SendingDelay, " seconds until next message.")
				BoxText(BoxMsg)
	
				IF SendingDelay > 0 THEN
					CurrentTime=TimeYmdHms( )  ; Gets Current Time
					WaitForTime = TimeAdd(CurrentTime, DelayDelta) ; Adds SendingDelay seconds to current time
					TimeWait(WaitForTime)  ; Waits for that time to occur
				ENDIF

			ENDIF

		ENDWHILE

		FileClose(handleAddressFile)

	RETURN

  
:SendEmail
	; Note: "AttachmentFileToSend" will be blank if the check box has not been checked
	; This is determined by the variable SendAttachment. Processing occurs once at higher level.
		SendStatus = -9999
		;Ignore blank lines
		IF SimulateSending == 1 THEN
			TimeDelay(2) ; Simulate message sending delay
			IF DebugClubMail == 1 THEN
				WhatSent = strcat("Sending the message and attachments... ", @CRLF, "To: ", tolist, @CRLF)
				WhatSent = StrCat(WhatSent,"Host: ", host, @CRLF,"From: ", fromaddr, @CRLF)
				WhatSent = strcat(WhatSent, "UserID: ",  userid,  @CRLF,"PW: ",password, @CRLF,"Port: ", port)
				Message ("Postie Simulator", WhatSent)
			ENDIF
		ELSE
			kInit(host,fromaddr,userid,password,port)
			kDest(tolist,cclist,bcclist)
			SendStatus = kSendFile(subject,ComboMessageFile,AttachmentFileToSend,flags)

			IF DebugClubMail == 1 THEN
				IF SendStatus == 0 THEN
					NotSent = strcat("Trouble sending the following: ", @CRLF, "To: <", tolist, ">", @CRLF,)
					NotSent = StrCat(NotSent, "Host: ", host, @CRLF,"From: ", fromaddr, @CRLF)
					NotSent = strcat(NotSent, "UserID: ",  userid,  @CRLF,"PW: ",password, @CRLF,"Port: ")
					NotSent = StrCat(NotSent, port, "Attachment: ", AttachFile)
					Message ("Problem with sending", NotSent)
				ENDIF
			ENDIF
		ENDIF
	
	RETURN

:ValidateEmailAddress
		EmailAddressOK = @TRUE

	RETURN

:DefineFunctions

		#DEFINEFUNCTION CreateInfoString (v)
			s = StrCat("Club Mail (Version ", v, ")", @CRLF)
			s = StrCat(s, "An imperfect solution to a little headache in a big world.", @CRLF, @CRLF)
			s = StrCat(s, "This is a 'bulk' email program designed for relatively small mailing lists such as club mailing lists.", @CRLF)
			s = StrCat(s, "It's designed to get around the limitations imposed by many ISPs to prevent spammers from abusing ", @CRLF)
			s = StrCat(s, "their system. ClubMail introduces a short delay (customizable) between each separate email sent to", @CRLF)
			s = StrCat(s, "people on an address list. A 3 second delay seems to work pretty well, but 'your mileage may differ.'", @CRLF, @CRLF)
			s = StrCat(s, "Each person on the address list gets a separate email addressed to him or her. Basically, the email", @CRLF)
			s = StrCat(s, "looks just like any other email, without a long list of 'To:' or 'Cc:' addresses.", @CRLF)
			s = StrCat(s, "ClubMail uses your regular internet connection, which must be active before sending mail. ", @CRLF, @CRLF)
			s = StrCat(s, "How many people can be on the address list? There's no real limit, other than that imposed by the delay.", @CRLF)
			s = StrCat(s, "If you have the delay set to 3 seconds, you can send about 15 'ordinary' emails per minute. Thus, an", @CRLF)
			s = StrCat(s, "address list with 3,000 members might take 200 minutes (about 3 hours) to process completely.", @CRLF)
			s = StrCat(s, "If you dropped the delay down to 1 second, it might take about one hour -- IF your ISP doesn't", @CRLF)
		   s = StrCat(s, "shut you down because it thinks you are spamming.", @CRLF, @CRLF)
			s = StrCat(s, "ClubMail is freeware, which means you may copy and distribute it for non-commercial purposes.", @CRLF)
			s = StrCat(s, "However, commercial rights are reserved.", @CRLF, @CRLF)
			s = StrCat(s, "Bug reports and suggestions for improvements may be sent to clubmail@iltc.net. However, we don't", @CRLF)
			s = StrCat(s, "make any promises to reply or to fix problems. A few pithy sayings (said with tongue firmly in", @CRLF)
			s = StrCat(s, "cheek!) might make this clearer: (1) If it breaks, it's your fault, and (2) You get what you pay for.")
			
			RETURN s
		#ENDFUNCTION

	
		#DEFINEFUNCTION EmailAddressOK(AddressToTest)
				IF AddressToTest == "" THEN
					RETURN @FALSE
				ELSE
					RETURN @TRUE
				ENDIF
		#ENDFUNCTION

		#DEFINEFUNCTION CreateAddressFileInfoString()
			s = StrCat("Structure and syntax of the address file:", @CRLF, @CRLF)
			s = StrCat(s, "The address file must be a simple ASCII text file. Each line in the file", @CRLF)
			s = StrCat(s, "corresponds to one email addressee. The format of each line is: ", @CRLF)
			s = StrCat(s, "     Email address ; Comment ", @CRLF)
			s = StrCat(s, "The comment is optional. If present, you must use the semi-colon as shown.", @CRLF, @CRLF)
			s = StrCat(s, "Examples of some valid entries in the file: ", @CRLF)
			s = StrCat(s, "     john999@hotmail.com", @CRLF)
			s = StrCat(s, "     mary100@yahoo.com ;", @CRLF)
			s = StrCat(s, "     susan33@earthlink.com ; Susan Jones (VP)", @CRLF, @CRLF)
			s = StrCat(s, "Examples of incorrect entries:", @CRLF)
			s = StrCat(s, "     john99                                                ", @CRLF)
			s = StrCat(s, "     john99@hotmail.com  John Jones      ", @CRLF)
			s = StrCat(s, "     john99@hotmail.com  John ; Jones    ", @CRLF)
			RETURN s
		#ENDFUNCTION

		#DEFINEFUNCTION CreateProfileOptionsString()
				s = StrCat("Profile options control how the program operates.", @CRLF, @CRLF)
				s = StrCat(s, "Show debug messages: If checked, some messages of interest to programmers are", @CRLF)
				s = StrCat(s, "      displayed during processing. Usually should not be checked.", @CRLF, @CRLF)
				s = StrCat(s, "Simulate mailing: If checked, ClubMail does not actually send any messages via", @CRLF)
				s = StrCat(s, "      the internet. Instead, it does all internal processing, then pretends to", @CRLF)
				s = StrCat(s, "      send the email -- but in reality, it does not do so. This is useful to", @CRLF)
				s = StrCat(s, "      test a new file containing email addresses.", @CRLF, @CRLF)
				s = StrCat(s, "Create 'good' and 'bad' address subfiles: If checked, the program will record", @CRLF)
				s = StrCat(s, "      all processed email addresses in one of two files. One file contains the", @CRLF)
				s = StrCat(s, "      addresses ClubMail thought were 'good' and the other file contains the", @CRLF)
				s = StrCat(s, "      'bad' addresses. The program creates the files, and tells you the name of", @CRLF)
				s = StrCat(s, "      the files at the completion of processing.", @CRLF, @CRLF)
				s = StrCat(s, "Show intro screen at program startup: If checked, the 'Introduction' screen is", @CRLF)
				s = StrCat(s, "      displayed at program startup. If not checked, the intro screen is disabled.", @CRLF)
				s = StrCat(s, "      Note: this is per-profile behavior.", @CRLF, @CRLF)
				s = StrCat(s, "Sending delay: This is the delay in seconds that ClubMail introduces between", @CRLF)
				s = StrCat(s, "      processing each email address. You can experiment with various settings.", @CRLF)
				s = StrCat(s, "      Generally, for very short emails you should enter a value between 3 and 5.", @CRLF)
				s = StrCat(s, "      For large emails, a value of 1 or 2 probably will be OK.", @CRLF)
				s = StrCat(s, "      The minimum value is one second. There is no maximum value, but you", @CRLF)
				s = StrCat(s, "      probably will not need to introduce more than a 5 second delay.", @CRLF)
			RETURN s
		#ENDFUNCTION

	RETURN


:Cancel
	; General purpose subroutine called whenever the user cancels a dialog
	IF CancelType == zzNormalCancel THEN
		UserCancel = @TRUE		
	ELSE 
		UserCancel == zzCriticalCancel THEN
		EXIT
	ENDIF
	IntControl(72, 2, 0, 0, 0) 	 ; Reset the cancel processing to "SUBROUTINE" styel... It defaults back to GOTO!
RETURN



:DoUpdateConfirm
MyDialogFormat=`WWWDLGED,6.1`

MyDialogCaption=`Please confirm action`
MyDialogX=222
MyDialogY=233
MyDialogWidth=154
MyDialogHeight=092
MyDialogNumControls=004
MyDialogProcedure=`DEFAULT`
MyDialogFont=`DEFAULT`
MyDialogTextColor=`DEFAULT`
MyDialogBackground=`DEFAULT,DEFAULT`
MyDialogConfig=0

MyDialog001=`037,047,072,012,PUSHBUTTON,DEFAULT,"Make the change",1,1,32,"Microsoft Sans Serif|5632|70|34","255|255|0","0|128|0"`
MyDialog002=`037,067,072,014,PUSHBUTTON,DEFAULT,"Do Not make the change",0,2,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog003=`007,007,138,012,VARYTEXT,ProfileWarning1,DEFAULT,DEFAULT,5,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog004=`007,023,138,018,VARYTEXT,ProfileWarning2,DEFAULT,DEFAULT,6,DEFAULT,DEFAULT,DEFAULT,DEFAULT`

ButtonPushed=Dialog("MyDialog")



RETURN



:DoMyDIalog
;;;; THE FOLLOWING LINE IS STATIC -- DO NOT UPDATE WHEN CHANGING THE FORM!
VersionInfo = StrCat("Version ", ClubMailVersion	 )

;;;; BEGIN THE FORM DEFINITION.

MyDialogFormat=`WWWDLGED,6.1`

MyDialogCaption=`ClubMail ... the "No Spam" Bulk Mailer`
MyDialogX=240
MyDialogY=062
MyDialogWidth=464
MyDialogHeight=336
MyDialogNumControls=070
MyDialogProcedure=`DEFAULT`
MyDialogFont=`DEFAULT`
MyDialogTextColor=`DEFAULT`
MyDialogBackground=`DEFAULT,DEFAULT`
MyDialogConfig=4513740

MyDialog001=`039,189,084,012,EDITBOX,host,default,DEFAULT,14,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog002=`241,003,038,012,PUSHBUTTON,DEFAULT,"Send Mail",1,8,32,"Microsoft Sans Serif|5632|70|34","192|192|192","0|128|0"`
MyDialog003=`297,003,038,012,PUSHBUTTON,DEFAULT,"Exit Program",2,9,DEFAULT,DEFAULT,DEFAULT,"218|170|122"`
MyDialog004=`039,201,084,012,EDITBOX,fromaddr,default,DEFAULT,16,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog005=`161,189,084,012,EDITBOX,userid,default,DEFAULT,15,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog006=`041,019,294,012,EDITBOX,subject,default,DEFAULT,1,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog007=`039,221,272,012,EDITBOX,AttachmentDir,default,DEFAULT,22,DEFAULT,DEFAULT,DEFAULT,"192|192|192"`
MyDialog008=`039,253,272,012,EDITBOX,AddressFile,default,DEFAULT,18,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog009=`011,191,028,008,STATICTEXT,DEFAULT,"SMTP host",DEFAULT,4,0,DEFAULT,DEFAULT,DEFAULT`
MyDialog010=`005,203,034,008,STATICTEXT,DEFAULT,"From address",DEFAULT,6,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog011=`135,203,024,010,STATICTEXT,DEFAULT,"Password",DEFAULT,8,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog012=`007,255,030,010,STATICTEXT,DEFAULT,"Address File",DEFAULT,8,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog013=`013,223,024,010,STATICTEXT,DEFAULT,"Attach Dir",DEFAULT,8,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog014=`019,021,020,010,STATICTEXT,DEFAULT,"Subject",DEFAULT,8,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog015=`141,191,020,010,STATICTEXT,DEFAULT,"User ID",DEFAULT,8,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog016=`161,201,084,012,EDITBOX,password,default,DEFAULT,17,16,DEFAULT,DEFAULT,DEFAULT`
MyDialog017=`267,299,066,010,STATICTEXT,DEFAULT,"Sending Delay (seconds)",DEFAULT,99,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog018=`007,271,030,010,STATICTEXT,DEFAULT,"Message Dir",DEFAULT,8,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog019=`039,269,272,012,EDITBOX,MessageDir,default,DEFAULT,20,DEFAULT,DEFAULT,DEFAULT,"192|192|192"`
MyDialog020=`313,253,020,012,PUSHBUTTON,DEFAULT,"FIND",3,19,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog021=`313,221,020,012,PUSHBUTTON,DEFAULT,"FIND",4,23,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog022=`313,269,020,012,PUSHBUTTON,DEFAULT,"FIND",6,21,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog023=`011,237,026,010,STATICTEXT,DEFAULT,"Attach File",DEFAULT,8,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog024=`039,235,272,012,EDITBOX,AttachmentFile,default,DEFAULT,6,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog025=`313,235,020,012,PUSHBUTTON,DEFAULT,"FIND",5,7,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog026=`007,111,032,008,STATICTEXT,DEFAULT,"Message File",DEFAULT,36,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog027=`041,109,272,012,EDITBOX,MessageFile,default,DEFAULT,3,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog028=`315,109,020,012,PUSHBUTTON,DEFAULT,"FIND",7,4,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog029=`039,165,064,012,EDITBOX,SectionName,default,DEFAULT,10,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog030=`007,167,032,008,STATICTEXT,DEFAULT,"Profile Name",DEFAULT,36,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog031=`111,165,038,012,PUSHBUTTON,DEFAULT,"Select Profile",8,11,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog032=`155,165,038,012,PUSHBUTTON,DEFAULT,"Update Profile",9,12,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog033=`199,165,038,012,PUSHBUTTON,DEFAULT,"Delete Current",10,13,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog034=`245,177,208,008,STATICTEXT,DEFAULT,"To create a new profile, change the name of the profile, then click ""Update Profile""",DEFAULT,45,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|128|128",DEFAULT`
MyDialog035=`245,157,208,008,STATICTEXT,DEFAULT,"To load an existing profile, click ""Select Profile""",DEFAULT,45,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|128|128",DEFAULT`
MyDialog036=`245,167,208,006,STATICTEXT,DEFAULT,"To delete a profile, load it, then click ""Delete Current""",DEFAULT,45,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|128|128",DEFAULT`
MyDialog037=`045,295,068,010,CHECKBOX,DebugClubMail,"Show debug messages",1,24,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog038=`045,305,052,010,CHECKBOX,SimulateSending,"Simulate mailing",1,27,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog039=`007,147,190,008,STATICTEXT,DEFAULT,"Profile Data (kept between sessions)",DEFAULT,51,DEFAULT,"Microsoft Sans Serif|6656|70|34","128|0|0",DEFAULT`
MyDialog040=`041,127,202,008,CHECKBOX,SendAttachment,"Send the attachment file (listed below in the profile) as an attachment.",1,5,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog041=`249,297,016,010,EDITBOX,SendingDelay,"5",DEFAULT,26,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog042=`041,035,294,068,MULTILINEBOX,MessageText,default,DEFAULT,2,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog043=`017,035,024,010,STATICTEXT,DEFAULT,"Message",DEFAULT,36,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog044=`337,021,102,008,STATICTEXT,DEFAULT,"You must enter a subject for this message.",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|0|255",DEFAULT`
MyDialog045=`345,255,104,008,STATICTEXT,DEFAULT,"Simple text file containing email addresses.",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|128|128",DEFAULT`
MyDialog046=`337,105,120,022,STATICTEXT,DEFAULT,"Optional message text file containing text to include in the body of the email. It may have HTML formatting.",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|0|255",DEFAULT`
MyDialog047=`335,271,104,008,STATICTEXT,DEFAULT,"Directory for the optional message file.",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|128|128",DEFAULT`
MyDialog048=`335,223,104,008,STATICTEXT,DEFAULT,"Default directory for the attachment.",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|128|128",DEFAULT`
MyDialog049=`337,037,100,016,STATICTEXT,DEFAULT,"A simple text-only message (no formatting) may be entered in this box.",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|0|255",DEFAULT`
MyDialog050=`337,053,104,022,STATICTEXT,DEFAULT,"The resulting email will be created from the text in this edit box, followed by the text in the ""message file"" (if any).",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|0|255",DEFAULT`
MyDialog051=`335,233,104,016,STATICTEXT,DEFAULT,"Any type of file may be specified as an attachment.",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","0|128|128",DEFAULT`
MyDialog052=`041,323,184,008,STATICTEXT,DEFAULT,"Copyright (c) 2003 ILTC. This program may be freely copied for personal use.",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","128|128|128",DEFAULT`
MyDialog053=`005,005,132,010,STATICTEXT,DEFAULT,"Message-specific information",DEFAULT,51,DEFAULT,"Microsoft Sans Serif|6656|70|34","128|0|0",DEFAULT`
MyDialog054=`227,323,112,008,STATICTEXT,DEFAULT,"However, all commercial rights are reserved.",DEFAULT,46,DEFAULT,"Microsoft Sans Serif|5632|40|34","128|128|128",DEFAULT`
MyDialog055=`123,295,126,012,CHECKBOX,ProcessAddressErrors,"Create 'good' and 'bad' address subfiles",1,25,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog056=`027,043,012,010,STATICTEXT,DEFAULT,"Text",DEFAULT,36,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog057=`007,141,442,004,STATICTEXT,DEFAULT,DEFAULT,DEFAULT,47,DEFAULT,DEFAULT,DEFAULT,"128|0|0"`
MyDialog058=`235,183,008,002,STATICTEXT,DEFAULT,DEFAULT,DEFAULT,47,DEFAULT,DEFAULT,DEFAULT,"64|128|128"`
MyDialog059=`235,155,008,002,STATICTEXT,DEFAULT,DEFAULT,DEFAULT,47,DEFAULT,DEFAULT,DEFAULT,"64|128|128"`
MyDialog060=`241,155,004,030,STATICTEXT,DEFAULT,DEFAULT,DEFAULT,62,DEFAULT,DEFAULT,DEFAULT,"64|128|128"`
MyDialog061=`123,305,138,010,CHECKBOX,iniShowSplashScreen,"Show intro screen at program start",1,28,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog062=`189,003,036,012,PUSHBUTTON,DEFAULT,"Help",11,64,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog063=`335,253,008,012,PUSHBUTTON,DEFAULT,"?",12,66,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog064=`247,201,008,012,PUSHBUTTON,DEFAULT,"?",13,67,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog065=`039,287,306,032,GROUPBOX,DEFAULT,"Profile Options",DEFAULT,63,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog066=`347,301,008,010,PUSHBUTTON,DEFAULT,"?",14,61,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog067=`125,189,008,012,PUSHBUTTON,DEFAULT,"?",15,68,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog068=`125,201,008,012,PUSHBUTTON,DEFAULT,"?",16,69,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog069=`247,189,008,012,PUSHBUTTON,DEFAULT,"?",17,70,DEFAULT,DEFAULT,DEFAULT,DEFAULT`
MyDialog070=`379,323,070,008,VARYTEXT,VersionInfo,"Version",DEFAULT,65,2,"Microsoft Sans Serif|5632|40|34","128|128|128",DEFAULT`

ButtonPushed=Dialog("MyDialog")


RETURN

Article ID:   W15852
File Created: 2004:03:30:15:41:08
Last Updated: 2004:03:30:15:41:08