Control Reference > VSPrinter Control > VSPrinter Properties > NPorts Property |
Returns the number of ports to which the current printer is connected.
val% = [form!]VSPrinter.NPorts
This property will return one unless you have devices with the same name connected to different ports.
For example, if the current Device is an "HP LaserJet 4L" connected to "LPT1:" and there's another "HP LaserJet 4L" connected to "LPT2:", then NPorts will return 2, Ports(0) will return "LPT1:", and Ports(1) will return "LPT2:".
Integer