VB coding in Word

En curso Publicado hace 7 años Pagado a la entrega
En curso Pagado a la entrega

I need assistance which should be a fairly straight forward issue, but for some reason I am struggling with it!

1)I need to create a form in Word that I can save to a shared drive.

2) I need to allow users to complete the form and press a SUBMIT button

3) The submit button will submit the form to "ANOther Person" via Outlook. It will prepopulate the 'To' address, 'subject line' and part of the body, but leave it open for the user to alter or add to the body message.

4) Once ANOther person receives the email, they can then authorise the form and press another submit button which will send the form on to '[url removed, login to view]'

5) If possible, the form will go to the SomeOne Else, plus 2 other email addresses, either by CC or within the 'To' line.

This is what I have been using on a macro-enabled word document.

Private Sub CommandButton1_Click()

Dim OL As Object

Dim EmailItem As Object

Dim Doc As Document

[url removed, login to view] = False

Set OL = CreateObject("[url removed, login to view]")

Set EmailItem = [url removed, login to view](olMailItem)

Set Doc = ActiveDocument

With EmailItem

.Subject = "Initial Request for a Trip or Event"

.Body = "Dear Paul" & vbCrLf & _

"Please find attached my initial request for a trip/event" & vbCrLf & _

"Thanks"

.To = "email address of person authorising the trip"

.[url removed, login to view] [url removed, login to view]

.Display

End With

[url removed, login to view] = True

MsgBox "Your request has been submitted. Thanks!"

Set Doc = Nothing

Set OL = Nothing

Set EmailItem = Nothing

End Sub

However, when the person receives the form, it is blank.

Can someone please write code that will work.

Thanks

Microsoft Office Microsoft Outlook Visual Basic Word

Nº del proyecto: #11638589

Sobre el proyecto

2 propuestas Proyecto remoto Activo hace 7 años

2 freelancers están ofertando un promedio de £26 por este trabajo

sergeyfishbein

Hi! I have a great expirience with Office programming and I want to take this project. My Skype: tarjatra

£18 GBP en 1 día
(5 comentarios)
2.7
theknightrider78

Good day! My name is k.R.. My principles are simple, clean and beautiful in the details. I am interested in your project because I have done similar projects in the past. I am always ready to push you towards your s Más

£33 GBP en 0 días
(0 comentarios)
0.0