Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27329

Margin center

$
0
0
Hello to all, is there code for center align text...

Code:

e.Graphics.DrawString(TextBox1.Text, font1, Brushes.Yellow, X, Y)
so X is pixels from left to right of paper, Y is from top to bootom. I try for X use insted number of pixels this code e.MarginBounds.Top - code puts only on top of the paper in left, not in center.

I need text in center - X.

thanks for any ideas...

Viewing all articles
Browse latest Browse all 27329

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>