Results 1 to 6 of 6
- 01-09-2013, 04:36 PM #1
Member
- Join Date
- Jan 2013
- Posts
- 3
- Rep Power
- 0
Urgent Help Needed for some minor Bluej Error
I tried this code , it works fine :-
But when i add a line for taking input , the red bar at left goes on progressing and it never runs ! Why ???Java Code:import java.util.*; public class god { public void main() { float chalnabey; Scanner in=new Scanner(System.in); System.out.println("t"); } }
Please help fast , tommorows my exams :(Java Code:import java.util.*; public class god { public void main() { float chalnabey; Scanner in=new Scanner(System.in); chalnabey=in.nextFloat(); //This is addition to last code System.out.println("t"); } }
-
Re: Urgent Help Needed for some minor Bluej Error
Could you explain what this means?
How are you sure that it never runs? Have you tried entering a number to see what happens?...and it never runs ! Why ???
It might be clearer to you that you need to enter a number if you add a prompt, a String that reminds you to enter data:
Also, we greatly appreciate it if you leave "urgent" and similar messages out of your question. Your question is no more important than any other question on this site. You'll be much better served if in your question heading you post a very brief summary of your current problem rather than non-specific text such as "urgent help needed for some ...". Tell us exactly what is wrong in that heading, but again, without the urgency.Java Code:import java.util.*; public class god { public void main() { float chalnabey; Scanner in=new Scanner(System.in); System.out.print("Please enter a number: "); chalnabey=in.nextFloat(); System.out.println("t"); } }Last edited by Fubarable; 01-09-2013 at 05:34 PM.
- 01-09-2013, 06:35 PM #3
Member
- Join Date
- Jan 2013
- Posts
- 3
- Rep Power
- 0
Re: Urgent Help Needed for some minor Bluej Error
I compiled , it compiles without any error but when i right click and select "new void main()" then JVM loader at left seems to load indefinatly , i didnt find any possible error in code but when i remove that line "chalnabey=in.nextInt();" , it works perfectly ?
Okay next time o=i will not use 'urgent' and similair words :)
- 01-09-2013, 08:38 PM #4
- 01-09-2013, 09:59 PM #5
Member
- Join Date
- Jan 2013
- Posts
- 3
- Rep Power
- 0
Re: Urgent Help Needed for some minor Bluej Error
Okay i have made a video itself for you to understand the situation :)
yakin - YouTube
- 02-07-2013, 03:19 PM #6
Member
- Join Date
- Jan 2013
- Location
- Kolkata,India
- Posts
- 59
- Rep Power
- 0
Re: Urgent Help Needed for some minor Bluej Error
okay if you are using BlueJ
then here is the error.your program works fine...but the red bar at left goes on progressing tells you that your program is running.
So what you have to do is open the terminal window by pressing Ctrl+t and the program shall run fine
regards
harshit
Similar Threads
-
Urgent Help Needed
By debu_cha in forum Advanced JavaReplies: 3Last Post: 12-07-2010, 09:02 PM -
ERROR DEPLOYING WEB APPLET......help needed urgent
By bonjovi4u in forum Java AppletsReplies: 1Last Post: 03-16-2010, 03:16 PM -
Urgent Help Needed
By Cid17 in forum New To JavaReplies: 10Last Post: 07-03-2009, 02:42 PM -
hi help needed, this is urgent
By msciriha in forum NetBeansReplies: 1Last Post: 02-07-2009, 06:16 PM -
Urgent help needed here pls!!
By Manfizy in forum NetBeansReplies: 5Last Post: 01-28-2009, 07:38 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks