Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / March 2006

Tip: Looking for answers? Try searching our database.

port currently owned by unknown windows application

Thread view: 
tolu45 - 29 Mar 2006 07:39 GMT
Dear All,

I have a problem with a code i am developing. I am trying to print the
result of a JList to a printer. I followed the example in the java
cookBook using CommAPI but when i try to print, i get the following
exception "port currently owned by unknown windows application". Can
anybody help by telling me how to solve this problem or how to go
around it. I have put a listener and set the waiting time to 30000sec
even at that, i never get the ownership of the port.

regards,
Noah.
JScoobyCed - 29 Mar 2006 07:56 GMT
> Dear All,
>
[quoted text clipped - 8 lines]
> regards,
> Noah.

I guess the windows driver is having the owership of the printer. Try
deleting the printer from your list of windows printers.

Signature

JSC

tolu45 - 29 Mar 2006 08:08 GMT
I am not sure if you are talking about the physical printer. If you
are, i can't delete it because i have only one network printer
installed.If i delete it how do i print?. If you are talking about the
software i create a new instance each time i want to print.

Thanks
Thomas Weidenfeller - 29 Mar 2006 13:37 GMT
> I have a problem with a code i am developing. I am trying to print the
> result of a JList to a printer. I followed the example in the java
> cookBook using CommAPI

How does that match with your later statement:

>>> i can't delete it because i have only one network printer
>>> installed.If i delete it how do i print?

You either have a physically connected printer, then JavaComm (you are
talking about JavaComm when you say CommAPI?) is a way to print to it
(but possibly the worst one can come up with), or you have a remote
printer. In the later case, JavaComm has no way to reach it at all.

You probably want to have a look at the real printing APIs in Java
instead of messing with JavaComm.

/Thomas
Signature

The comp.lang.java.gui FAQ:
ftp://ftp.cs.uu.nl/pub/NEWS.ANSWERS/computer-lang/java/gui/faq
http://www.uni-giessen.de/faq/archiv/computer-lang.java.gui.faq/

Roedy Green - 29 Mar 2006 20:42 GMT
>I have a problem with a code i am developing. I am trying to print the
>result of a JList to a printer. I followed the example in the java
[quoted text clipped - 3 lines]
>around it. I have put a listener and set the waiting time to 30000sec
>even at that, i never get the ownership of the port.

That is not the way you would normally print, unless you were using
some specialised printer not supported by the OS.  See
http://mindprod.com/jgloss/printing.html
Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.