Th code below may need adjustments from one Excel version to other.
Common recommendation is: record the macro in Excel, and translate VBA code to VFP.
With oExcel.ActiveSheet.PageSetup
.LeftMargin = oExcel.Application.InchesToPoints(1)
.RightMargin = oExcel.Application.InchesToPoints(0.5)
.....
EndWith
>Hi
>I´m generating a excel sheet from VFP, everything is Ok, but need to set left and right margins before printing the sheet. How can I do that?
>
>Thanks in advance..
>Carlos Burgos