Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 84
Default change size of object

Sub changesquare()
Sheets("IZEN").activate
ActiveSheet.Shapes("izensquare").Select
Selection.ShapeRange.ScaleHeight Range("f4").Value, msoFalse,
msoScaleFromTopLeft
Selection.ShapeRange.ScaleWidth Range("d4").Value, msoFalse,
msoScaleFromTopLeft
Range("a1").Select
End Sub

this changes the object by a percentage, how do i go about changing the size
to like inches, if in f4 it says 5 have it 5inches, not 500% of current size

thanks in advance
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 226
Default change size of object

You can set the pixel size of the shape like this:

Sub changesquare()
Sheets("IZEN").Activate
ActiveSheet.Shapes("izensquare").Select
Selection.ShapeRange.Height = Range("F4").Value
Selection.ShapeRange.Width = Range("D4").Value
Range("A1").Select
End Sub

So for 5 inches your value in D4 would need to somewhere in the high hundreds.

Hope this helps
Rowan

"choice" wrote:

Sub changesquare()
Sheets("IZEN").activate
ActiveSheet.Shapes("izensquare").Select
Selection.ShapeRange.ScaleHeight Range("f4").Value, msoFalse,
msoScaleFromTopLeft
Selection.ShapeRange.ScaleWidth Range("d4").Value, msoFalse,
msoScaleFromTopLeft
Range("a1").Select
End Sub

this changes the object by a percentage, how do i go about changing the size
to like inches, if in f4 it says 5 have it 5inches, not 500% of current size

thanks in advance

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
change font size on screen, but prints in old size lvrcdval Excel Discussion (Misc queries) 2 July 19th 07 02:36 PM
change scaling % but font size didnt change porportionally, pls he Scaling question Excel Discussion (Misc queries) 0 March 12th 07 03:16 AM
Calendar - change of a size of this object Drahos Excel Worksheet Functions 1 February 14th 06 06:01 PM
size of embedded object Amy Wang Excel Discussion (Misc queries) 0 December 9th 05 10:15 PM
Set the size of a chart object Thomas Wieser Excel Programming 3 April 13th 04 11:16 AM


All times are GMT +1. The time now is 04:25 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"