+ Reply to Thread
Results 1 to 6 of 6

Macro to add an embedded object and resize to certain dimensions

  1. #1
    Registered User
    Join Date
    04-08-2009
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    15

    Macro to add an embedded object and resize to certain dimensions

    I would like a macro to embed a PDF (not the icon option) and resize it too 6.8" heigth 6.38" width. So far i can just get it to embed and any other macro i add to resize the object will not work. I think it has to do with the object name changing each time a new one is added. I tried to create a macro to change the name to object 1 but that did not work either. All i have so far is the following.

    Please Login or Register  to view this content.
    Last edited by Eamster; 09-04-2013 at 12:42 PM.

  2. #2
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Macro to add an embedded object and resize to certain dimensions

    Try this:
    Please Login or Register  to view this content.
    Remember what the dormouse said
    Feed your head

  3. #3
    Registered User
    Join Date
    04-08-2009
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    15

    Re: Macro to add an embedded object and resize to certain dimensions

    I tried that and it did change the size but it looks like it kept the aspet ratio so it made it smaller than the intended dimensions. Also it didn't really embed anything that could be accessed. It was just a blank box when clicked on just brought up a window to add another object.

  4. #4
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Macro to add an embedded object and resize to certain dimensions

    You can turn off the aspect ratio lock using:
    Please Login or Register  to view this content.
    When I run that I get prompted to choose a pdf file, just as I would if attempting to insert a new PDFXML file manually.

  5. #5
    Registered User
    Join Date
    04-08-2009
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    15

    Re: Macro to add an embedded object and resize to certain dimensions

    Ok that sized it perfectly. The only issue is that it is just a blank white box. No pdf showing.

    I get prompted and add one and when i do it acts as if it adds it but nothing shows up and nothing can be accessed to open the file up.

    I have also found that when i click on it that it is just an autoshape and not an object anymore.
    Last edited by Eamster; 09-04-2013 at 12:34 PM.

  6. #6
    Registered User
    Join Date
    04-08-2009
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    15

    Re: Macro to add an embedded object and resize to certain dimensions

    Ok I closed out of everything and retried it and it worked. Thanks!!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Resize the image according to the cell dimensions.
    By yeshwant_sur in forum Excel General
    Replies: 1
    Last Post: 02-28-2013, 03:05 AM
  2. Insert picture and auto rotate and resize to cell range dimensions
    By jwagman1 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-01-2012, 03:49 PM
  3. Embedded PDF Object positioning using Macro
    By timepass111 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-21-2011, 03:24 PM
  4. Resize icon representing embedded object using VBA
    By NateofCA in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-17-2010, 03:05 AM
  5. Constant display of dimensions of object label.
    By famdamly in forum Excel General
    Replies: 2
    Last Post: 03-25-2007, 10:30 PM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1