I made a method but it not run ok
I add this data
DATA nMargTop,nMargLeft,nMargBottom,nMargRight AS NUMERIC INIT 0
DATA lMargin, hSolidPen
and on the New method
::hSolidPen := CreatePen (PS_DOT, 1, CLR_GRAY)
::nMargTop := 15
::nMargLeft := 15
::nMargBottom := 15
::nMargRight := 15
::lMargin = .T.
and I add a new method
- Code: Select all Expand view
METHOD SMargin() CLASS Tpaper
if !::lMargin
return nil
endif
::oWnd:GetDC()
MoveTo( ::oWnd:hDC ,;
::nMargTop ,;
::nMargLeft )
LineTo( ::oWnd:hDC ,;
::nMargTop ,;
::nMargLeft ,;
::hSolidPen:hPen )
MoveTo( ::oWnd:hDC ,;
::nMargTop ,;
::nMargRight )
LineTo( ::oWnd:hDC ,;
::nMargRight ,;
::nMargBottom ,;
::hSolidPen:hPen )
::oWnd:ReleaseDC()
return nil
and I add ::Smargin() on the PaintMeta method
Some can help me please ?