<code>
Node node = new Circle(100, 200, 200);
PrinterJob job = PrinterJob.createPrinterJob();
if (job != null) {
boolean success = job.printPage(node);
if (success) {
job.endJob();
}
}
</code>
I run the code above on windows xp, but it doesn't work. I try to debug it. It seems like the com.sun.glass.ui.Application.GetApplication() method return null, what cause GetApplication()._invokeAndWait(runnable) which in com.sun.glass.ui.Application.invokeAndWait(Runnable) method throw NullPointException.
Any help will be appreciated.
Node node = new Circle(100, 200, 200);
PrinterJob job = PrinterJob.createPrinterJob();
if (job != null) {
boolean success = job.printPage(node);
if (success) {
job.endJob();
}
}
</code>
I run the code above on windows xp, but it doesn't work. I try to debug it. It seems like the com.sun.glass.ui.Application.GetApplication() method return null, what cause GetApplication()._invokeAndWait(runnable) which in com.sun.glass.ui.Application.invokeAndWait(Runnable) method throw NullPointException.
Any help will be appreciated.