You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I need to create an android application, with basic functionality that when the user taps print(UI button) the app should automatically send print requests to some printer, with no user input in printer selection at that exact moment and no print preview should be displayed. There could be printer selection(configuration) but it should not bother the user every time it wants to print (it should ask the user for printer selection only one time or occasionally).
So after some research, I found out about this library and it seems like the thing I need. I tried to implement it but no luck, I don't know how to use it to scan for available printers and their Uri.
I get this error trying to send print to HPLaserJetP1102W :
java.net.SocketTimeoutException: connect timed out
W/System.err: at com.ivanjanikj.bistroprinting.HttpIppClientTransport.sendData(HttpIppClientTransport.java:42)
This library doesn't implement discovery at present. In Android you can use JMDNS (a separate Java library) or if you are targeting modern Android OS only, NsdManager.
I'm leaving this open because implementing discovery using either method would be a good addition.
Hi,
I need to create an android application, with basic functionality that when the user taps print(UI button) the app should automatically send print requests to some printer, with no user input in printer selection at that exact moment and no print preview should be displayed. There could be printer selection(configuration) but it should not bother the user every time it wants to print (it should ask the user for printer selection only one time or occasionally).
So after some research, I found out about this library and it seems like the thing I need. I tried to implement it but no luck, I don't know how to use it to scan for available printers and their Uri.
I get this error trying to send print to HPLaserJetP1102W :
java.net.SocketTimeoutException: connect timed out
W/System.err: at com.ivanjanikj.bistroprinting.HttpIppClientTransport.sendData(HttpIppClientTransport.java:42)
I have created HttpIppClientTransport exactly like this example -> https://github.com/HPInc/jipp/blob/master/sample/jprint/src/main/java/sample/HttpIppClientTransport.javri
I think the problem is that I'm using the wrong Uri when creating this code block
{
URI uri = URI.create("http://192.168.1.100:631/ipp/print");
IppPacket printRequest = IppPacket.printJob(uri)
.putOperationAttributes(documentFormat.of("application/pdf")))
.build();
transport.sendData(uri, new IppPacketData(printRequest, new FileInputStream(inputFile)));
}
My question is: How to find the URI of every WIFI printer using this library, is there some method that I can use, that I'm not aware of?
Thank you
The text was updated successfully, but these errors were encountered: