Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. VB PRINTER OBJECT PROBLEM

VB PRINTER OBJECT PROBLEM

Scheduled Pinned Locked Moved Visual Basic
jsonhelpquestion
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    Cheickna
    wrote on last edited by
    #1

    Hi Every body I want to use VB object printer to print some informations exactly at a position (x, y) on paper. I understand each printer has its own idea of what the printable area of the paper is. Therefore i use Windows API to check left and top margin before sending data to printer. I retrieve theses informations like this : MarginLeft = GetDeviceCaps(Printer.hdc, PHYSICALOFFSETX) MarginTop = GetDeviceCaps(Printer.hdc, PHYSICALOFFSETY) With my own printer MarginLeft = 42 pixels ( 2.96666 mm ) idem for MarginTop Now, i tried to print a dot (.) at position (0,0) like this, just to check: Printer.CurrentX=0 Printer.CurrentY=0 Printer.print "." On my paper (A4) i obtain this result with ruler : Left Margin = 2.9666 mm (~ 3 mm) BUT Top margin ~ 6 mm. I dont understand why Top margin is 6 mm insted of 3 Is there any way to know where come this more 3 mm ? Is there any way to set to force printer Unprintable area ? Thanks in advance Cheickna

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups