I have this program that converts an old report format for an accounting package into postscript form for sending to laser printers. The Socket communication to network printers works perfectly.

How could i go about sending the data to a windows shared laser printer if i know the hostname and the printer sharename?

Any help would be much appreciated.
Thanks,
David