Sometimes, the printer can be reached from Windows command/console box (cmd.exe or command.com).
The printer's address is in the form \\pathofnetwrok\nameofprinter.
Write "type foo.dat >\\pathofnetwrok\nameofprinter".
Sometimes, the printer can be reached via FTP.
Open a connection using the IP address of the printer.
Issue a "put foo.dat" command to send the file to the printer.
It depends on the type of the printer. I only recently discovered that there is an lpr.exe program in Windows (at least XP; probably w2k; NT4?, W9x??). How to do it from a program see attached files.
* The Best Reasons to Target Windows 8
Learn some of the best reasons why you should seriously consider bringing your Android mobile development expertise to bear on the Windows 8 platform.