04-17-2014 3:13 PM
HI,
I want my MS word page color to be grey when called from SAP, tried various option but it is not working. Please provide me your suggestions.
04-17-2014 3:30 PM
Which shade of gray do you feel like using. I hear there are fifty shades
04-17-2014 3:35 PM
Hi Manish -
Any shade of gray is ok for me. What is the syntax to use? Thanks for your response.
04-17-2014 3:48 PM
You might have seen some sample codes of OLE. The way they get the object, and then get/set attribute.
The VB macro code for setting background to 25% darker gray would be:
ActiveDocument.Background.Fill.ForeColor.ObjectThemeColor = wdThemeColorBackground1
ActiveDocument.Background.Fill.ForeColor.TintAndShade = -0.25
ActiveDocument.Background.Fill.Visible = msoTrue
ActiveDocument.Background.Fill.Solid
You have to execute these commands using OLE.
04-17-2014 3:50 PM
Try to translate in OLE2 a recorded macro code like (here a light grey...)
ActiveDocument.Background.Fill.ForeColor.ObjectThemeColor = wdThemeColorBackground1
ActiveDocument.Background.Fill.ForeColor.TintAndShade = -0.15
ActiveDocument.Background.Fill.Visible = msoTrue
ActiveDocument.Background.Fill.Solid
Regards,
Raymond