S
sjgregory
Hello, I am creating an application in MS Access that opens various Publisher templates, modifies and saves them.
I have set up references to MS Publisher, and using the following variables can add shapes etc. via code:
Dim pubApp As publisher.Application
Dim pubDoc As publisher.Document
Then, after creating instances of the variables, the following, for example, works:
Set shpTextBox = pubDoc.Pages(4).Shapes.AddTextbox _
(Orientation:=pbTextOrientationHorizontal, _
Left:=100, Top:=200, _
Width:=100, Height:=40)
BUT, when I try to change the colorscheme, using:
pubDoc.ColorScheme = pubApp.ColorSchemes("WildFlower")
I get an "invalid procedure call or argument error."
Any ideas for a fix are greatly appreciated.
I have set up references to MS Publisher, and using the following variables can add shapes etc. via code:
Dim pubApp As publisher.Application
Dim pubDoc As publisher.Document
Then, after creating instances of the variables, the following, for example, works:
Set shpTextBox = pubDoc.Pages(4).Shapes.AddTextbox _
(Orientation:=pbTextOrientationHorizontal, _
Left:=100, Top:=200, _
Width:=100, Height:=40)
BUT, when I try to change the colorscheme, using:
pubDoc.ColorScheme = pubApp.ColorSchemes("WildFlower")
I get an "invalid procedure call or argument error."
Any ideas for a fix are greatly appreciated.