-
running applets on web page
I am trying to run an applet into my web page. The applet will load but when I try to display calculations in the test field or text area nothing happens. The code works fine on my computer. If I take out the string and parsing functions and just hard code a literal string within quotes it will display that.
I have attached one of the functions for reference, I hope this is okay. This is the first time I have posted anything here.
if (source == timeButton){
double paceIn = Double.parseDouble (paceField.getText());
double distanceIn = Double.parseDouble(distanceField.getText());
double timeValue = (distanceIn * paceIn);
String timeText = Double.toString(timeValue) + " ";
timeText = timeText.substring(0,5);
answerField.setText("It will take you approximately " + timeText + " minutes.");
I also had to change all my components from J components to just applet components because nothing would run with the J Components. Could it be the server? Would it help if I attached the entire java file?
Please help.
Frustrated,
Candace
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks