Private Sub Command0_Click()
Dim rec As Long
Dim stWhere As String '-- Criteria for DLookup
Dim varTo As Variant '-- Address for SendObject
Dim stText As String '-- E-mail text
Dim RecDate As Variant '-- Rec date for e-mail text
Dim stSubject As String '-- Subject line of e-mail
Dim varserial_num As Variant '-- The ticket ID from form
Dim varWho As Variant '-- Reference to tblUsers
Dim strSQL As String '-- Create SQL update statement
Dim myDate As Variant '-- Current Date
Dim varmgr As Variant
Dim errLoop As Error
Dim Err_EMail As Error
On Error GoTo Err_Command0_Click
myDate = Date
rec = CurrentRecord
Dim db As Database
Dim rs As Recordset
Dim mailList As String
varWho = Email
' varmgr = manager_ee
' This Code was Generated by ikon1\mrettberg
If IsNull(varWho) Or varWho = "" Then 'IsNull variable is null it evaluates to True the Or varWho = "" covers an empty string
MsgBox "Please Enter A Valid E-Mail Address Prior To Attempting Notification", , "Incomplete Information"
Exit Sub
End If
varserial_num = Serial_num
RecDate = Date
'DLookup to Term Database for End User Name
' varTo = DLookup("[end user]", "Term", "[serial_num] = [Forms]![term_sub]![serial_num]")
' varUser = DLookup("[User]", "Term", "[serial_num] = [Forms]![Term_sub]![serial_num]")
stSubject = "Return of Computer Assets from Termination of " & [User]
stText = "Good Day to You: " & [SUPERVISOR_NAME] & vbCrLf & vbCrLf & _
"This letter is to inform you that we have received termination notice of " & [User] & _
" on " & [Act_Term_date] & " and we are inquiring as to the return of his or her computer equipment." & vbCrLf & vbCrLf & _
"We have a couple of loose ends to tie up and then we will be all set." & vbCrLf & vbCrLf & _
"1.I need for you to check the bag and verify all accessories are present" & vbCrLf & _
"2.I need for you to place the laptop inside the laptop bag. Place the bag into a box with at least 2 inches of packing material on all 6 sides (top, bottom, and all four sides) and ship it overnight ... with an insured value of $3500 to the following address: " & RecDate & vbCrLf & vbCrLf & _
"Asset ID: " & Asset_ID & vbCrLf & _
"Asset Type: " & Asset_Type & vbCrLf & _
"Serial #: " & Serial_num & vbCrLf & vbCrLf & _
"Mitch Rettberg" & vbCrLf & _
"10 Patewood Drive" & vbCrLf & _
"Suite 300 Building 6" & vbCrLf & _
"Greenville, SC 29615" & vbCrLf & vbCrLf & vbCrLf & vbCrLf & _
"Send me an email with the Property of IKON Number & Tracking Number at mrettberg@ikon.com" & vbCrLf & _
"That is all" & vbCrLf & vbCrLf & _
LstBox = (User) & _
"Thank you and have a Great Day"