MDO3000 Programmer Manual.pdf - 第365页
Commands Listed in Alphabetical Order Email printer: T o add an email printer at labprn3@example.com: HARDCopy:PRIN Ter:ADD "lab prn3@example.com " HARDCopy:PRINT er:DELete (No Query Form) Removes a ne twork pr…

Commands Listed in Alphabetical Order
HARDCopy:PRI
NTer:ADD (No Query Form)
This command is used to add a network or email printer to the list of available
printers. Adding a network printer requires 3 arguments, but only one of server
name or serve
r IP address should be specified. An empty string can be used for
blank arguments. Adding an email printer requires only one argument.
Group
Hard Copy
Syntax
HARDCopy:PRINTer:ADD
<name>,<server>,<address>|<emailaddress>
Arguments
Network printers:
<name> is the name of the network printer queue.
<server> is the host name of the print (LPR) server.
<address> is the IP address of the print server.
Specify
ing the printer name and server name or server address adds a network
printer to the list of available printers. All three arguments must be present, but
only one of server name or server IP address should be specified. An empty
string should be used for the second or third argument (server name or server
address) which is not specified. If both are specified and neither is an empty
string, then the server name takes precedence.
Email printers:
<emailaddress> is the internet email address of the printer. Must contain an
@ character.
Specifying only a single argument, the printer email address adds an email printer
to the list of available printers, as does specifying 2 or more arguments where the
first argument contains an @ character. When the first argument contains an @
symbol, the command is interpreted as a request to add an email printer and,
therefore, any additional arguments are ignored.
Examples
Network printer:
To add a networ
ked printer called 'labprn1', hosted from a compatible print server
called 'printhost.example.com':
HARDCopy:PRINTer:ADD "labprn1", "prin thost.example.com",
""
To add a networked printer called 'labprn2', hosted from a print server at IP
address '192.168.0.20':
HARDCopy:PRINTer:ADD "labprn2", "", "192.168.0.20 "
2-334 MDO4000/B/C, MSO/DPO4000B and MDO3000 Series Oscilloscopes Programmer Manual

Commands Listed in Alphabetical Order
Email printer:
To add an email printer at labprn3@example.com:
HARDCopy:PRINTer:ADD "labprn3@example.com"
HARDCopy:PRINTer:DELete (No Query Form)
Removes a ne
twork printer from the list of available printers. The printer name
is case sensitive.
Group
Hard Copy
Syntax
HARDCopy:PRINTer:DELete <name>
Arguments
<name> is the name of the printer to be deleted.
HARDCopy:PRINTer:LIST? (Query Only)
Displays the list of currently defined printers.
The fields for each entry represent the printer number, whether the printer is
currently active (Y=active, N=inactive), the printer name, the printer type (USB,
Net or Email), print server name or IP address.
Group
Hard Copy
Syntax
HARDCopy:PRINTer:LIST?
Examples
With a single printer configured, the HARDCopy:PRINTer:LIST? query might
return a result similar to the following:
"1:Y:labprn1:Net:printhost.example.com:;"
HARDCopy:PRINTer:REName (No Query Form)
Renames a network or email printer on the list of available printers, replacing
the currently stored settings with the settings specified in the command. The
first argument can be either the printer name, or the index from querying
HARDCopy:PRINTer:LIST?
MDO4000/B/C, MSO/DPO4000B and MDO3000 Series Oscilloscopes Programmer Manual 2-335

Commands Listed in Alphabetical Order
Group
Hard Copy
Syntax
HARDCopy:PRINTer:REName
<name>,<new_name>,<new_server>,<new_address>
Arguments
Network printer:
<index> | <name> is the name of the printer to be renamed (dele
ted).
<new_printer_name> is the new name for this printer.
<new_server_name> is the new print server for this printer.
<new_server_address> is the new IP address for the server.
All four arguments must be present when renaming a network printer to another
network printer. Either the server name or the server IP address should be
specified, but not both. An empty string or server address should be used for the
third or fourth argument (server name or server address) which is not specified.
If both are specified, and neither is an empty string, t
hen the server name takes
precedence. which is not specified.
If the second argument contains an @ symbol, the comm
and is interpreted as
a request to rename an existing printer to an email printer and, therefore, any
additional arguments are ignored.
Email printer:
<index> | <name> is the index or name of the printer
to be renamed.
<new pr inter email address> is the new email address for this printer.
If the second argument contains an @ symbol, the command is interpreted as
a request to replace the printer entry with an email printer and, therefore,any
additional arguments are ignored.
Examples
Network printer:
If the first entry on the printer list is for a network printer called 'labprn1', either of
the following commands could be used to change the print server for the printer
to 'newserver.example.com':
HARDCopy:PRINTer:REName "labprn1", "l abprn1",
"newserver.example.com", ""
HARDCopy:PRINTer:REName 1, "labprn1",
"newserver.example.com", ""
Using the same example printer list entry, the name of the network printer could
be changed to 'labprn2' with either of the following commands:
2-336 MDO4000/B/C, MSO/DPO4000B and MDO3000 Series Oscilloscopes Programmer Manual