Hi
I have a userform in excel that copies text from a cell and puts it within a bookmark in a word template. I have created code which works however the issue i have is that i require more than 1 cell value to populate into a single bookmark with a space between the paragraphs. Hope someone can help. Thanks
I have a userform in excel that copies text from a cell and puts it within a bookmark in a word template. I have created code which works however the issue i have is that i require more than 1 cell value to populate into a single bookmark with a space between the paragraphs. Hope someone can help. Thanks
sub ExportButton(control As IRibbonControl)
Dim objWord As Object
Dim ws As Worksheet
Set ws = ThisWorkbook.Sheets("Testing")
Set objWord = CreateObject("Word.Application")
objWord.Visible = True
objWord.Activate
objWord.Documents.Open "\\Desktop\Testing.dotm"
With objWord.ActiveDocument
.Bookmarks("RPD").Range.Text = ws.Range("E10").Value
.Bookmarks("RPD").Range.Text = ws.Range("E12").Value
.Bookmarks("RPD").Range.Text = ws.Range("E14").Value
End With
Set objWord = Nothing
End Sub