Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by arminro

  1. arminro

    C# metric transformation

    well i've traced and debug-ed a bit. PrintPageEventArgs e.MarginBounds and e.PageBounds are correct and to the exact dimensions i need them to be. as in (if i select A4 paper) 827 in hundreads of an inch, 8,27 in normal inches. i've set the richtext box Client size to this width as you have seen...
  2. arminro

    C# metric transformation

    umm maybe if i'll show you the code i'll explain better: Graphics g=this.outputrichbox.CreateGraphics(); g.PageUnit=GraphicsUnit.Inch; g.PageScale=1; PointF[] bottom=new PointF[3]; bottom[0]=new PointF((float)this.pageSetupDialog1.PageSettings.PaperSize.Width/100,1); bottom[1]=new...
  3. arminro

    C# metric transformation

    a few things. first thanks .. because you've shed some light on this. it works to a certain point. as in the width of the richtextbox is about fine, but the text isn't how i desired to be. there are diferences betwin the print version and the one i show on the screen and i think it's because of...
  4. arminro

    C# metric transformation

    in your example g.Dpix is the device horizontal Dpi(dots per inch). dots however are not pixels.
  5. arminro

    C# metric transformation

    how do i transform inches to pixels and viceversa ? if it was c++ i'd use the device context functions lptodp and lptohimetric but i need a C# solution. i need to resize some richtextboxes to an exact size(on screen). the thing is the size i need to set it to is in inches and i need pixels...

Part and Inventory Search

Back
Top