how to retrive paper sizes of default printer
See the following :
Dim pp As New PrinterSettings
Dim p1 As PaperSize = Nothing
For Each ps As PaperSize In pp.PaperSizes
If ps.PaperName.Contains("A4") Then
p1 = ps
TextBox1.Text = p1.Width
TextBox2.Text = p1.Height
TextBox3.Text = p1.Kind 'paper size
TextBox4.Text = p1.RawKind
when i set HP Laser Jet 1022 printer as default printer then
i am not getting proper value as paper size
e.g. for A4, paper size is 9 but i am getting some other value.
so is there any other code to get proper paper size to all printer.