Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #12  
Old 12-05-2014, 02:15 PM
macropod's Avatar
macropod macropod is offline How to click on one picture, and another picture will be shown? Windows 7 64bit How to click on one picture, and another picture will be shown? Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

An alternative for Word 2007 & later is to use a picture content control & simply resize that when clicked. The code to do that would be like:
Code:
Private Sub Document_ContentControlOnEnter(ByVal ContentControl As ContentControl)
With ContentControl
  If .Title = "MyPic" Then
    With .Range.InlineShapes(1)
      If .Width > CentimetersToPoints(1) Then
        .Width = CentimetersToPoints(1)
      Else
        .Width = CentimetersToPoints(4)
      End If
    End With
  End If
End With
End Sub
Much simpler than using MACROBUTTON fields, as is required for Word 2003 & earlier.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Move Picture by picture name, rename picture by picture name CatMan PowerPoint 2 04-18-2012 12:21 PM
How to click on one picture, and another picture will be shown? Right-click has Edit Picture greyed out Nick.Ryan Drawing and Graphics 1 02-15-2012 09:40 PM
Powerpoint automatically changing picture size when adding a picture (2010) One_Life PowerPoint 7 01-20-2012 06:57 AM
Right-click on a picture in Word munchoa Word VBA 1 10-01-2011 10:03 AM
How to click on one picture, and another picture will be shown? "format picture" - arrows show as no line atop picture marbeth Word 3 07-08-2011 02:16 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 06:38 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft