Link to home
Start Free TrialLog in
Avatar of photoman11
photoman11Flag for United States of America

asked on

Problems applying image effects to multiple images at the same time in Microsoft Word 2007

Hello experts,

I'm using a Windows 7 environment on a desktop, and primarily use Microsoft Word 2007 for document creation. I have an ongoing project which is becoming more and more frequent and the number of images keeps growing also. Therefore I'm looking for help on doing the same thing I'm currently doing but being able to apply the steps to multiple images rather than one image at a time. here's the process I generally go through:

1. After identifying a large number of images (generally between 200-500 per document), I use a Microsoft Word macro to insert the images in a 3 row by 2 column format of 6 images per page. This produces a good starting point of 6 images nicely centered in 2 columns on each page.

2. I then select a border/digital frame to apply to the images by double-clicking on one image and choosing a border from the options presented. I have not been able to figure out how to apply the same border to EITHER all of the images in that document; or to large groups of images in the document (excluding images that have already been loaded that have borders/digital frames).

Therefore, what I wind up doing is applying the border/frame to 1 image, and then use Format Painter to click on each of the remaining 200-500 individual images. It would be such a help to know if there is a way to do this in one pass.

3. For the final step, I go through and reduce the size of images which are overlapping other images. I maintain the aspect ratio while reducing the size. I usually wind up reducing anywhere from 30%-50% of the total number of images. I have not been able to figure out any way to do this, other than on an image by image basis.

I realize that each image is a different size, but if there is any way to designate a certain percentage or some other way to apply the reduction to all images, it would save me a huge amount of labor, to say nothing of my diminishing sanity.

After researching the Microsoft Word help functions as well as general Internet searches, the term "drawing canvas" came up several times, but I don't see how that would apply or be useful, as a first step in grouping of images, which I also cannot figure out how to successfully do.

One of the forums mentioned that Text Wrapping needed to be said at ANYTHING OTHER THAN in-line with text, in order to be able to apply the same effect to multiple images in one step. I tried several different text wrapping choices without finding any way to successfully apply any of the above steps to more than one image of the time.

Anything you can advise to help in this area would be hugely appreciated!

As additional background, the Word macro was developed for me because I have no clue how to do it. I don't know if there's anything in the macro that is contributing to the issue or whether it can be solved by making changes in it. Let me know if you want to look at it and I will attach it.

Thank you very much.
Avatar of GrahamSkan
GrahamSkan
Flag of United Kingdom of Great Britain and Northern Ireland image


As I recall, the macro that you are using inserted in line pictures into table cells. By fixing the cell size, this method is able to preserve the layout and to control the picture size. Inline pictures are treated like (large) characters. Unfortunately you cannot select non-contiguous text, so selecting multiple inline shapes is not possible in the same way as you can with 'floating' shapes. For this the shapes would have to be formatted away from inline in order to apply the same attributes to each at the same time

I'm not sure why the picture need resizing, because each should automatically fit its table cell.

This macro will format add the same border to all the inline shapes in a document:

 
Sub FormatBorders()
    Dim ilsh As InlineShape
    Dim brd As WdBorderType
    Application.ScreenUpdating = False
    For Each ilsh In ActiveDocument.InlineShapes
        For brd = wdBorderRight To wdBorderTop
            With ilsh.Borders(brd)
                .ColorIndex = wdDarkRed
                .LineStyle = wdLineStyleSingle
                .LineWidth = wdLineWidth600pt
            End With
        Next brd
    Next ilsh
    Application.ScreenUpdating = True
End Sub

Open in new window


It might make more sense to incorporate it in the original macro, so  I think that you will eventually have to grasp the nettle and to get to understand VBA.
Avatar of photoman11

ASKER

Graham,

I'm sure you're right, however I'm so deluged with projects right now that there is no way that I can do it. So let me do this ...

I will include some screenshots (including the original macro) and ask you to take a look at it as a paid project. I assume you'll want more details than I will include in this post so I will e-mail you outside of expert exchange and we can go from there.

Are you open to that?

Thanks,

Robert
all-images-with-borders.png
border-extends-past-image.png
Current-macro-for-inserting-imag.txt
ASKER CERTIFIED SOLUTION
Avatar of GrahamSkan
GrahamSkan
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks, I will e-mail you at your other address.
To update this question. You are applying borders with the use of the new picture styles. These are not supported in VBA, but require XML manipulation.
Graham,

I guess I should close this out although I'm not sure where to go next. Did you get my last e-mail sent to you at the non-expert exchange address?
Yes. Close this. I have sent a couple of replies to genone16@.... Should I be talking to CPE or Bez?
Graham,

I did receive your e-mails, with the last one being on May 4. I will close out this post and you can contact me through the genone16 address.

Thanks