Link to home
Start Free TrialLog in
Avatar of evo14sale
evo14sale

asked on

string length in pixels when drawing??

i want to be able to know how many pixels are within a specific font and size, im printing. my printing page will be separated into columns and i want to know when a specific string length has meet the pixel size length for the column(i have called this variable xincrease. does any one know how to work this out?



        Dim pageboundleft As Integer
        Dim pageboundright As Integer
        Dim pageboundtop As Integer
        Dim pageboundbottom As Integer

        pageboundleft = e.MarginBounds.Left
        pageboundright = e.MarginBounds.Right
        pageboundtop = e.MarginBounds.Top
        pageboundbottom = e.MarginBounds.Bottom

'gets column width in pixels?
        Dim xincrease As Integer = (pageboundright - pageboundleft) / (gridcolmax + 1)




   
ASKER CERTIFIED SOLUTION
Avatar of wguerram
wguerram

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial