Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Private Sub Command1_Click()
- Dim AlApp As Object
- Dim objmail As Object, signature As String
- On Error Resume Next
- Set olApp = GetObject(, "Outlook.Application") 'Outlook needs to be open.
- If Err Then 'If outlook is not open.
- Set olApp = CreateObject("Outlook.Application") 'Create a new instance of outlook.
- End If
- Set objmail = olApp.CreateItem(0)
- Dim email_body As String
- email_body = email_body & "<span style=""font-size: 11pt""><font face=Calibri+Body>Dear," & "<br>" & "<br>"
- email_body = email_body & "We note from our records that it has been almost 12 months since your equipment was last calibrated." & "<br>" & "<br>"
- email_body = email_body & "Please see details below. " & "<br>" & "<br>"
- 'TABLE
- email_body = email_body & "TABLE" & "<br>"
- email_body = email_body & "TABLE" & "<br>"
- email_body = email_body & "TABLE" & "<br>" & "<br>"
- 'TABLE
- email_body = email_body & "It is crucial that instruments are serviced and calibrated regularly to ensure sufficient accuracy for their professional use. A maximum time between laboratory calibrations is specified in standards, monitoring protocols and quality management systems." & "<br>" & "<br>"
- email_body = email_body & "<ul><li> If you wish to <b>proceed with the calibration</b>, please let me know and we will be happy to provide you with a price for calibration, services available and delivery options. </ul></li> "
- email_body = email_body & "<ul>Just call ANV Measurement Systems <b>(01908 642 846) to book your calibration, then:</ul></b>"
- email_body = email_body & "<ul>- Send or bring your equipment to us with a purchase order</ul>"
- email_body = email_body & "<ul>- Or ask us to collect the instruments from your location</ul>" & "<br>"
- email_body = email_body & "<ul><b>Alternatively</b></ul> "
- email_body = email_body & "<ul><li> Visit our website to <b>book your calibration</b> online <b><a href=http://www.noise-and-vibration.co.uk/><span style=""color: MidnightBlue"">www.noise-and-vibration.co.uk</span></b></a></ul></li>" & "<br>"
- email_body = email_body & "Here at ANV Measurement Systems we are able to offer calibration support on a huge range of acoustic and vibration equipment <b>(UKAS accredited laboratory No 0653)</b>." & "<br>" & "<br>"
- email_body = email_body & "<b>We provide a quick turnaround service for your calibration needs, normally 5 working days.</b>" & "<br>" & "<br>" & "<br>"
- email_body = email_body & "<b><em><span style=""color: MidnightBlue"">Don't miss out on the fantastic Extended Warranty Offer (up to 6 years) when you have your Rion instrumentation calibrated annually (or in accordance with UKAS Publication Lab 23) by ANV Measurement Systems.</em></span>" & "<br>" & "<br>"
- email_body = email_body & "<span style=""color: MidnightBlue""><b>If you can't afford to be without your instrumentation during a repair or calibration, we can also offer equipment hire at a reduced rate.</b></span></font></b></span>" & "<br>" & "<br>"
- With objmail
- .Display
- End With
- Dim ssta, ssto
- signature = objmail.HTMLbody
- ssta = InStr(signature, "<body")
- ssto = InStr(signature, "</body>")
- signature = Mid(objmail.HTMLbody, ssta, ssto - ssta)
- ssta = InStr(2, signature, "<")
- signature = Mid(signature, ssta, Len(signature))
- 'signature = Mid
- With objmail
- .From = "Bbogdan@anv.uk.com"
- .to = huj
- .CC = "calibration@anv.uk.com"
- .Subject = "Calibration Reminder for your consideration"
- .HTMLbody = email_body & vbNewLine & signature
- End With
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement