PC Review


Reply
Thread Tools Rate Thread

Align text in a text box

 
 
Ana
Guest
Posts: n/a
 
      15th Jul 2009
Hi;

I have a text box and I want to justified the text using a macro I have the
following code :


ActiveSheet.Shapes("Text Box 1").Select
Selection.Characters.Text = ""
With Selection.Font
..Name = "Calibri"
..FontStyle = "Regular"
..Size = 9

End With

and it works but I do not know how to justified the text
Anybody knows??

thank you



 
Reply With Quote
 
 
 
 
Peter T
Guest
Posts: n/a
 
      15th Jul 2009
Dim shp As Shape
Set shp = ActiveSheet.Shapes("Text Box 1")
shp.TextFrame.HorizontalAlignment = xlJustify

Regards,
Peter T

"Ana" <(E-Mail Removed)> wrote in message
news:2FC71269-1EE5-4CBF-B79E-(E-Mail Removed)...
> Hi;
>
> I have a text box and I want to justified the text using a macro I have
> the
> following code :
>
>
> ActiveSheet.Shapes("Text Box 1").Select
> Selection.Characters.Text = ""
> With Selection.Font
> .Name = "Calibri"
> .FontStyle = "Regular"
> .Size = 9
>
> End With
>
> and it works but I do not know how to justified the text
> Anybody knows??
>
> thank you
>
>
>



 
Reply With Quote
 
Ana
Guest
Posts: n/a
 
      15th Jul 2009
Thank you a lot

"Peter T" wrote:

> Dim shp As Shape
> Set shp = ActiveSheet.Shapes("Text Box 1")
> shp.TextFrame.HorizontalAlignment = xlJustify
>
> Regards,
> Peter T
>
> "Ana" <(E-Mail Removed)> wrote in message
> news:2FC71269-1EE5-4CBF-B79E-(E-Mail Removed)...
> > Hi;
> >
> > I have a text box and I want to justified the text using a macro I have
> > the
> > following code :
> >
> >
> > ActiveSheet.Shapes("Text Box 1").Select
> > Selection.Characters.Text = ""
> > With Selection.Font
> > .Name = "Calibri"
> > .FontStyle = "Regular"
> > .Size = 9
> >
> > End With
> >
> > and it works but I do not know how to justified the text
> > Anybody knows??
> >
> > thank you
> >
> >
> >

>
>
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
align text to the right of a bullet in a text box Aprilbyrd Microsoft Powerpoint 1 12th Apr 2008 09:01 AM
<div align=center> also affects align of dynamic dropdown item text Steve Richter Microsoft ASP .NET 1 24th Jun 2007 08:11 PM
How to right align text but left align lines on first character? =?Utf-8?B?bXNjZXJ0aWZpZWQ=?= Microsoft Word Document Management 1 10th Aug 2006 09:48 PM
Can I align text on the bottom of a text box, instead of the top? =?Utf-8?B?TWludXRlbWFu?= Microsoft Word Document Management 2 2nd Dec 2005 07:28 PM
how to Align text left & vertical align middle Kay Microsoft ASP .NET 2 25th Jul 2003 09:32 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:44 AM.