How Can i Draw a box 290mm x 210mm in a dialog

Post Reply
devwin2004
Posts: 42
Joined: Mon Dec 05, 2005 1:27 am

How Can i Draw a box 290mm x 210mm in a dialog

Post by devwin2004 »

Dear Coleagues

How Can i Draw a box 290mm x 210mm (exact dimension)
inside a dialog on screen

Thanks

Dante
devwin2004@yahoo.com.ar
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Dante,

In class TPrinter you have this method:

Code: Select all

METHOD Cmtr2Pix( nRow, nCol ) CLASS TPrinter

   if ValType( ::nYoffset ) == "U"
    ::nYoffset := 0
   endif
   if ValType( ::nXOffset ) == "U"
    ::nXoffset := 0
   endif

   nRow := Max( 0, ( nRow * 10 * ::nVertRes() / ::nVertSize() ) - ::nYoffset )
   nCol := Max( 0, ( nCol * 10 * ::nHorzRes() / ::nHorzSize() ) - ::nXoffset )

return { nRow, nCol }
you may use its code to turn the mm into pixels.
regards, saludos

Antonio Linares
www.fivetechsoft.com
Post Reply