N
Naz
Hi all
I have a form that has a list box populated with documents. The user clicks
to highlight the one that they are interested in and clicks a button to open
the template.
But when the template, a word *.dot file, opens it doesn't open as a new
document based on the template the file opens with *.dot in the title and any
changes that are made and saved change the *.dot file.
But if i open the files from explorer they open as *1.doc and the *.dot file
remains unchanged.
This is the code i use to open the files
Private Sub cmdOpenTemplate_Click()
On Error GoTo Err_cmdOpenTemplate_Click
DocTarget = Me.ReportRepository
DocLink = DLookup("[DocLocation]", "tbl_Documents", "[DocName] = '" &
DocTarget & "'")
Application.FollowHyperlink DocLink
Exit_cmdOpenTemplate_Click:
Exit Sub
Err_cmdOpenTemplate_Click:
MsgBox Err.Description
Resume Exit_cmdOpenTemplate_Click
End Sub
Anyone know how to make it open as a new document based on the template, am
i missing some paramter or something.
All help is greatly appreciated.
_______________________
Naz,
London
I have a form that has a list box populated with documents. The user clicks
to highlight the one that they are interested in and clicks a button to open
the template.
But when the template, a word *.dot file, opens it doesn't open as a new
document based on the template the file opens with *.dot in the title and any
changes that are made and saved change the *.dot file.
But if i open the files from explorer they open as *1.doc and the *.dot file
remains unchanged.
This is the code i use to open the files
Private Sub cmdOpenTemplate_Click()
On Error GoTo Err_cmdOpenTemplate_Click
DocTarget = Me.ReportRepository
DocLink = DLookup("[DocLocation]", "tbl_Documents", "[DocName] = '" &
DocTarget & "'")
Application.FollowHyperlink DocLink
Exit_cmdOpenTemplate_Click:
Exit Sub
Err_cmdOpenTemplate_Click:
MsgBox Err.Description
Resume Exit_cmdOpenTemplate_Click
End Sub
Anyone know how to make it open as a new document based on the template, am
i missing some paramter or something.
All help is greatly appreciated.
_______________________
Naz,
London