LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 08-23-2002, 06:48 AM   #1
northfield
LQ Newbie
 
Registered: Aug 2002
Location: UK
Distribution: mandrake, redhat
Posts: 29

Rep: Reputation: 15
Program should work, but not displaying


Java programming on linux

I am getting this display problem. The program works on windows and linux but not where I favour to work from.

[sidte5115@node00 w0109699]$ cd Bank
[sidte5115@node00 Bank]$ appletviewer NorthfieldBanque.java
Xlib: connection to "whale.cscs.qmw.ac.uk:49.0" refused by server
Xlib: Client is not authorized to connect to Server
Exception in thread "main" java.lang.InternalError: Can't connect to
X11
window
server using 'whale.cscs.qmw.ac.uk:49.0' as the value of the DISPLAY
variable
.
at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
at
sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:5
9)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:120)
at
java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvi
ronment.java:58)
at java.awt.Window.<init>(Window.java:188)
at java.awt.Frame.<init>(Frame.java:315)
at java.awt.Frame.<init>(Frame.java:262)
at sun.applet.AppletViewer.<init>(AppletViewer.java:139)
at
sun.applet.StdAppletViewerFactory.createAppletViewer(AppletViewer.jav
a:81)
at sun.applet.AppletViewer.parse(AppletViewer.java:1035)
at sun.applet.AppletViewer.parse(AppletViewer.java:969)
at sun.applet.Main.run(Main.java:140)
at sun.applet.Main.main(Main.java:82)
[sidte5115@node00 BankCW1]$


I have tried

man xhost


I have read this very small manual but it doesn't help.

I have tried 4 different servers: whale, cetacean, porpoise and
dolphin. All gave the same error.

The last server I tried via dolphine, it works on this but the laboratory is favoured by first year undergradutes.
 
Old 08-23-2002, 11:30 AM   #2
crabboy
Senior Member
 
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
Try typing 'xhost +' before executing the appletviewer.
 
Old 08-23-2002, 01:53 PM   #3
northfield
LQ Newbie
 
Registered: Aug 2002
Location: UK
Distribution: mandrake, redhat
Posts: 29

Original Poster
Rep: Reputation: 15
Thank you
This works
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Will my program work under Linux matthewm Linux - Newbie 10 11-13-2005 05:37 PM
How does a C Program Work? TGWDNGHN Programming 12 09-30-2005 06:46 PM
Problem displaying program output when driven by a cron job garmon Linux - Newbie 1 07-22-2004 02:34 PM
IBM Recovery Program won't work fcnewbie Linux - Newbie 5 06-25-2004 08:47 PM
cannot get program to work using WINE dev1gig Linux - Software 0 08-09-2003 11:43 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 07:42 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration