+ Reply to Thread
Results 1 to 10 of 10

Formatting Width and Length of Shapes

  1. #1
    Registered User
    Join Date
    09-04-2013
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    21

    Question Formatting Width and Length of Shapes

    Hi all,

    Am trying to find a way to format the Width and Length of shapes, like maybe a rectangle, according to a value in a cell, however do not know whats the exact formula or steps to do it. (Some formulas or Conditional Formatting?)
    Say, the Width is according to value in G3 and the length is according to I3.
    Thanks in advance!

    Cheers,
    Heva
    Last edited by Heva; 09-13-2013 at 08:13 AM.

  2. #2
    Registered User
    Join Date
    09-04-2013
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Formatting Width and Length of Shapes

    Bumping in hope to find a helping hand for this.
    Thanks!

  3. #3
    Registered User
    Join Date
    09-04-2013
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Formatting Width and Length of Shapes

    Hi all,

    Hoping to get a helping hand for this problem.
    Thanks!

  4. #4
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,436

    Re: Formatting Width and Length of Shapes

    you can use a user defined function

    Please Login or Register  to view this content.
    Attached Files Attached Files
    Cheers
    Andy
    www.andypope.info

  5. #5
    Registered User
    Join Date
    09-04-2013
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Formatting Width and Length of Shapes

    Quote Originally Posted by Andy Pope View Post
    you can use a user defined function

    Please Login or Register  to view this content.
    Pardon me due to my limited skills in Excel,
    How do I assign this to the "Rectangle"?
    Do I go to "Assign Macro"?

  6. #6
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,436

    Re: Formatting Width and Length of Shapes

    I thought I had attached an example.

    You can use the udf in a cell.
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    09-04-2013
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Formatting Width and Length of Shapes

    Quote Originally Posted by Andy Pope View Post
    I thought I had attached an example.

    You can use the udf in a cell.
    My apologies I must have missed that.

    I had tried applying the exact same given as your example into my template however i got the error ###### (as shown in cell C25)
    As attached is what I am working on and hope you will be able to help me see what I had done wrongly.
    What I want to achieve is the rectangle box to size according to the values given in W and L so that I will be able to see if the box will be able to fit into the pallet (as highlighted using conditional formatting).

    Cheers!
    Attached Files Attached Files

  8. #8
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,436

    Re: Formatting Width and Length of Shapes

    You need to add the function to the workbook otherwise it will not work.

    You may need to convert those values to to the correct scaling for shapes.
    The routine is using the value as the points size for width / length
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    09-04-2013
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Formatting Width and Length of Shapes

    Quote Originally Posted by Andy Pope View Post
    You need to add the function to the workbook otherwise it will not work.

    You may need to convert those values to to the correct scaling for shapes.
    The routine is using the value as the points size for width / length
    I tried navigating around with a new excel sheet but could not find any way to add in the function.
    Will it be possible to explain step by step in details? (I am really weak with excel)
    Sorry to be causing trouble as I will need to explain it out instead of just blindly taking and using the new template you had already done it for me. ><

  10. #10
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,436

    Re: Formatting Width and Length of Shapes

    start by putting require code in a standard code module.

    ALT+F11 (open VBE}
    menu Insert > Module
    paste user defined function code.

    In worksheet cell enter user defined function call along with arguments regarding shape name and width / length

  11. #11
    Registered User
    Join Date
    09-04-2013
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Formatting Width and Length of Shapes

    Roger that!
    Thanks alot Andy!
    Really appreciate your help much! ^^

+ 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. [SOLVED] Length and width from four columns to one
    By Christopher Lynch in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 02-19-2013, 07:30 PM
  2. Shapes 'straight connector' has a limited height/length in macros?
    By pfrattali in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-14-2011, 02:09 AM
  3. How to autoformat cell length/width to your data set?
    By cmf0106 in forum Excel General
    Replies: 1
    Last Post: 10-22-2009, 04:01 PM
  4. How to autoformat cell length/width to your data set?
    By cmf0106 in forum Excel General
    Replies: 1
    Last Post: 10-22-2009, 02:56 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