Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Another one:
Option Explicit Sub testme() Dim myRect As Shape Dim myCell As Range Dim cCtr As Long With Worksheets("sheet1") Set myRect = .Shapes("rectangle 3") Set myCell = .Range("J17") For cCtr = 1 To Len(myCell.Text) Step 255 With myRect.TextFrame .Characters(.Characters.Count + 1).Insert _ String:=Mid(myCell.Text, cCtr, 255) End With Next cCtr End With End Sub Tiago wrote: i'm adding to a rectangle a text from a range 1 by 1 character like this: ActiveSheet.Shapes("Rectangle 3").Select For i = 1 To Len(Range("J17")) Selection.Characters.Text = Selection.Characters.Text + Mid(Range("J17").Value, i, 1) Next It works, but when i arrives to 255 don't let me fill the rest of the rectangle. Anyone Help? Thanks -- Dave Peterson |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Rectangle Symbol | Excel Discussion (Misc queries) | |||
Rectangle Box | Excel Worksheet Functions | |||
Rounded Rectangle | Excel Programming | |||
Resizeable Rectangle | Excel Programming | |||
Add text to a rectangle in VBA | Excel Programming |