You can’t easily force things like margins and orientation, all you can do is use

dlgPrint->PrinterSettings->DefaultPageSettings->Landscape = true;

Which if not forced and often ignored leaving the user to have to decide.

Detecting Page Orientation

You can do this in the print page callback:

	void DataGridViewPrint::PrintDoc_PrintPage(System::Object ^sender, System::Drawing::Printing::PrintPageEventArgs ^e)
		if (e->PageSettings->Landscape)		//True for landscape
Feel free to comment if you can add help to this page or point out issues and solutions you have found. I do not provide support on this site, if you need help with a problem head over to stack overflow.


Your email address will not be published. Required fields are marked *