Results 1 to 3 of 3
  1. #1
    3 Star Lounger
    Join Date
    Apr 2003
    Location
    Calgary, Alberta
    Posts
    327
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Inserting and resizing an image (Word 2000/Access 2000)

    I would like to automatically populate a doc file with a pciture that comes from Access. In Access, I have an unbound frame object that has my image, which at one point gets the focus on it and a command copies it. Once it is copied, the word 2000 file is open, and put into the specific bookmark. Since I am copying the file from Access into word, the image becomes to big in the word file (The image is 300 dpi. When i insert an image normally, the size is correct) Therefore, I would like to know how I can resize the image getting pasted automatically with VBA?

    Thanks

    Shimmer

  2. #2
    Super Moderator
    Join Date
    Dec 2000
    Location
    New York, NY
    Posts
    2,970
    Thanks
    3
    Thanked 29 Times in 27 Posts

    Re: Inserting and resizing an image (Word 2000/Access 2000)

    Here's a snippet of code that does something similar (although the graphic file did not come from Access) - does this help any?:

    <pre>Selection.InlineShapes.AddPicture _
    FileName:=sWorkGroupPath & sFileName, _
    LinkToFile:=False, SaveWithDocument:=True
    Selection.MoveLeft Unit:=wdCharacter, Count:=1, Extend:=True
    'Scale the logo:
    With Selection.InlineShapes(1)
    Select Case sGraphicKey
    Case "Team-work"
    .Height = MillimetersToPoints(80)
    .Width = MillimetersToPoints(200)
    </pre>

    Gary

  3. #3
    3 Star Lounger
    Join Date
    Apr 2003
    Location
    Calgary, Alberta
    Posts
    327
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Inserting and resizing an image (Word 2000/Access 2000)

    Hi Gary, I solved the problem a little while ago, similar to what you have below. I don't have to worry about resizing anything anymore, cause the insert works perfectly.

    Thanks for your help

    Shimmer

Posting Permissions

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