Board index » delphi » Word - How to remove TextBox border

Word - How to remove TextBox border

How can I remove de border-line of the textbox in Word ?

code Textbox in Word

Box := WordDocument.Shapes.AddTextbox( msoOrientationHorizontal, 400, 20,130,50, EmptyParam);

Box.TextFrame.TextRange.Text := '.......';

 

Re:Word - How to remove TextBox border


Quote
> How can I remove de border-line of the textbox in Word ?

I would like to know this too.  After recording a macro in EXCEL,  the
following is how EXCEL does it.  However,  I am stll having a problem.   I
can see the name of the Shaperange but when i request the pointer i get the
message "A null referecne pointer was passed to the stub".

Any thoughts?????????????????

ws: _Worksheet;
wsShape: Shape;
wsr: ShapeRange;

         wsShape := ws.Shapes.AddTextbox(1,160,1,200,90);
         wsShape.Name := 'PROText';
         for x := 1 to ws.Shapes.Count do
            if ws.Shapes.Range[x].Name = 'PROText' then
            begin
               wsr := ws.Shapes.Range[x];
               wsr.Fill.Visible := msoFalse;
               wsr.Fill.Solid;
               wsr.Fill.ForeColor.SchemeColor := 9;
               wsr.Fill.Transparency := 0;
               wsr.Line.Weight := 0.75;
               wsr.Line.DashStyle := $00000001;
               wsr.Line.Style := $00000001;
               wsr.Line.Transparency := 0;
               wsr.Line.Visible := msoFalse;
            end;

Re:Word - How to remove TextBox border


With wich code can I remove te borderline of the textbox in Word ?

Code:

Box := WordDocument.Shapes.AddTextbox( msoTextOrientationHorizontal, 30, 20, 100, 100, EmptyParam);
Box.TextFrame.TextRange.Text :='........';

Thanks

Re:Word - How to remove TextBox border


<<Erwin:
With wich code can I remove te borderline of the textbox in
Word ?

Quote

var
  Box: Word2000.Shape;
..
  Box := Doc.Shapes.AddTextbox(
                msoTextOrientationHorizontal,
                30, 20, 100, 100, EmptyParam);
  Box.Line.Visible := msoFalse;
  Box.TextFrame.TextRange.Text :=
                'This text has no border';

--
Deborah Pate (TeamB) http://delphi-jedi.org

  Use Borland servers; TeamB don't see posts via ISPs
  http://www.borland.com/newsgroups/genl_faqs.html

Other Threads