Hi. I've got a short bit of VBA that someone kindly provided from another forum but it doesn't run giving an error:
runtime error 91
Object variable or with block variable not set
The code is:
Private Sub Document_Open()
DIM ThisDocument as Document
ThisDocument.DataProviders("YourDPNameHere"
.Refresh
End Sub
As I'm unfamiliar with VBA I'm unable to debug it. Can anyone here help. It's purpose is to refresh just one DP in the report on open.
Many thanks
runtime error 91
Object variable or with block variable not set
The code is:
Private Sub Document_Open()
DIM ThisDocument as Document
ThisDocument.DataProviders("YourDPNameHere"
End Sub
As I'm unfamiliar with VBA I'm unable to debug it. Can anyone here help. It's purpose is to refresh just one DP in the report on open.
Many thanks