Consulting

Results 1 to 4 of 4

Thread: Solved: Hide Graphic Image in Word

  1. #1
    VBAX Regular
    Joined
    Sep 2008
    Location
    Wyoming
    Posts
    41
    Location

    Solved: Hide Graphic Image in Word

    Hi There,

    I have a Word macro\template with two graphic images in the header. One for a state seal and another for a department.
    The template will have two states - draft and final. In the draft state I need to hide the images which I am able to do but only for the Print Layout view (I know it is an option to turn on). When I click on the Full Screen reading the images appear.

    Is it possible to hide them on the document and not just the view??

    I have a command button for the final version which turns the graphic on for the Print Layout view.
    With ActiveWindow
    With .View
    .ShowPicturePlaceHolders = True
    .ShowDrawings = True
    End With
    End With

    Or should I just make two bookmarks and on the final version do a pastespecial for each to the respective bookmark?

  2. #2
    Knowledge Base Approver VBAX Guru macropod's Avatar
    Joined
    Jul 2008
    Posts
    4,435
    Location
    Hi mphill,

    If you create a custom document property (File|Properties|Custom) to hold the document's staus, you could use an IF formula field to test the status and display/hide the images accordingly. For example, if the custom property's name is 'Status' and setting this to 'Final' denotes the finalised document, then you could use an IF field coded like:
    {IF{DOCPROPERTY Status \* Upper}= "FINAL" "Graphic"}
    where you graphic is position where the text 'Graphic' appears. If you're using a floating object (eg formatted as square), you'll need to position its anchor in the position indicated by 'Graphic'.

    Note: The field brace pairs (ie '{ }') for the above example are created via Ctrl-F9 - you can't simply type them or copy & paste them from this message.
    Cheers
    Paul Edstein
    [Fmr MS MVP - Word]

  3. #3
    VBAX Regular
    Joined
    Sep 2008
    Location
    Wyoming
    Posts
    41
    Location
    Thank you for the reply and I set that up.

  4. #4
    VBAX Regular
    Joined
    Sep 2008
    Posts
    39
    Location
    had same issue and worked wonders. thanks!!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •