Hi!
I have started to create a sub which should populate bookmarks in a word template.. Seemed pretty damn easy.. But nono.. It's harder than i thought..
It just throws me a runtime error 424 "object needed"?
Why is that.. I have double checked and can confirm that there is a bookmarknamed content.
I have started to create a sub which should populate bookmarks in a word template.. Seemed pretty damn easy.. But nono.. It's harder than i thought..
It just throws me a runtime error 424 "object needed"?
Why is that.. I have double checked and can confirm that there is a bookmarknamed content.
Code:
Dim wrdapp As Word.Application
Dim wrddoc As Word.Document
Set wrdapp = CreateObject("word.Application")
wrdapp.Visible = True
Set wrddoc = wrdapp.Documents.Add("C:\Documents and Settings\QUJF\Skrivbord\Superhandläggning\mallv2.dot")
wrddoc.Bookmarks("content").Range.Text = TextBox12.Text