使用Java,減去異常處理,這很簡單,只要如何將原始打印機代碼從ruby寫入Windows打印機共享?
FileOutputStream ostream = new FileOutputStream("\\\\host\\share");
PrintStream printStream = new PrintStream(ostream);
printStream.print("HELLO PRINTER");
printStream.close();
ostream.close();
目前不適用於jruby – russellkt 2009-03-02 16:33:25