4,084 Posted Topics
Re: [QUOTE=tygerberg;347836]Hi i must do a programming project of my own choice. [/QUOTE] kind off says it all ... you're supposed to choose it yourself, so you can take a topic that you find interesting so you'll stay motivated. another reason is because they want to see whether or not you … ![]() | |
Re: make use of Java's features and create your own Objects (classes) for (for instance) your players, .. even if you're not familiar with the use of classes yet, you should write more methods, and minimize the lines of code you place in your main method. I see that your main … | |
![]() | Re: [QUOTE=jeanfrg;1192494]Hi I'm a java intermediate student, I have been studying java for two years. I just wanted to offer my help to those students that are currently struggling with java in general, or those who need help on an assignment. Lately I have been ahead of my class so I … ![]() |
Re: within a few pages, this code will become almost impossible to read/maintain. you could familiarize yourself with the use of servlets, and use those to perform all the tasks you want to be done. when reading further on the use of requests en responses, you'll figure out how to pass … | |
Re: [QUOTE=zyaday;1185524]Following me everywhere? why do I get those exceptions very much??? why are they raised?? My classes are always in the same package as the class they accesses them.. I know they are there. Why doesn't the compiler find them???? thanks for your help ppl...please help :@[/QUOTE] don't know, you're … | |
Re: [QUOTE=beginner233;1186457]There is a nicer way to say shit. [/QUOTE] yet you don't seem to use it. you'll be getting help if you're willing to put some effort in it yourself, not by just expecting us to do it for you. yes, our knowledge of and experience in Java programming exceeds … | |
Re: seriously, you're not wasting bandwith by posting your exceptions on the forum instead of expecting us to open an attachement. very few of us actually will, you know | |
Re: [QUOTE=eedriz utman;1184939]i need more explanation on it.[/QUOTE] no you don't. you gave all the explanation to find the answer in your first post: it's a PATTERN that you want to PRINT there are only very basic techniques used there, no doubt your teacher showed you those. | |
Re: don't just 'explain' show us the code you've written so far | |
Re: [QUOTE=Ron2794;1184899]Hey guys ........plz can you suggest me any project wic uses simple java and sql and may be connectivity between java and sql I am in 12th standard and want to make a good project related to above items......................[/QUOTE] a GOOD project with only SIMPLE java and sql? part of … | |
Re: [QUOTE=Ezzaral;1184373]Haven't you learned anything from your previous posts asking others to do your work for you? Get to work and show some effort.[/QUOTE] Ezzaral (almost) said all there is to say, except for the correct answer to your question, which is: yes | |
Re: by putting a loop in your code, which depends on the value of a boolean. the startvalue is 'true', since you want the code to run at least once. you just adjust the value of this boolean before you rerun the loop. you could do this like this: [Code=Java] import … | |
Re: you don't need special software to create jar files. you can use any archiving program to do so (winzip, winrar, 7-zip, ...) all you need to do is know how the structure of a .jar file is | |
Re: you've got quite a number of typo's in there. just the main things you should correct first: a variable name has to be unique, so you can not have several JTextFields with the name 'p' if you call your button 'exitButton', don't be surprised if the compiler does not know … | |
Re: [QUOTE=snowball14;1180301]Can anyone tell me what I am doing wrong? I can't get it to calculate the charges.[/QUOTE] what you're doing wrong? you didn't paste your code in your post | |
Re: [QUOTE=java=hard;1181608]I think it might be too late. The assignment is due in about 30 minutes.[/QUOTE] wow ... talking about efficiënt time management :| | |
Re: [QUOTE=herat_000;1178886]It results in an error ….[/QUOTE] could you be just a tad more specific about this part? what error is thrown, what error message do you get, where is it thrown, ... | |
Re: you could use xsl:fo, I assume. | |
Re: take a closer look at your main method, I've pointed out the things to correct below: [QUOTE=KSUliz;1179187] [Code=Java] //main method executes at run time public static void main(String args[]) { //method to add new text to the JTextPane { // REMOVE THIS BRACKET Document doc = textPane.getDocument(); try { //clear … | |
Re: read all the data, change what you want to change, and write it (not appending) to the file | |
Re: I'll give you a couple of hints, that caught my eye without really deep-reading the code: [Code=Java] .. gradesL = new JLabel("Enter your grades: ",SwingConstants.RIGHT); .. grade1TF = new JTextField(5); .. calculateB = new JButton("Calculate"); [/Code] change the above code (and everything like it) to [Code=Java] JLabel gradesL = new … | |
Re: what have you tried so far, what does it do, what is it supposed to do? looks to me like your teacher gave you that code and said: 'put an undo and hint option into the following code' | |
Re: tried [URL="http://www.lmgtfy.com/?q=set+max+length+of+input+in+jtextfield"]this[/URL] yet? | |
Re: [QUOTE=sabah_786;1179840] 1) For Button 1 - Check Balance, I want to firstly bar out the pin number so it doesn't show. How do I do this? [/QUOTE] you could make your own input screens, instead of the JOptionPane standards, and use a JPasswordField instead of a JTextField [QUOTE=sabah_786;1179840] How can … | |
Re: best start, though: grab your course books, and study them a bit. no professor will ask you to write a gui if you don't understand enough of the java basics to actually use it. your first step should be, try to write it yourself. if it doesn't work, show us … | |
Re: [QUOTE=Krstevski;1179211]Or [CODE=java] ... [/CODE] But this code is not tested.[/QUOTE] don't just hand out code. the purpose of this forum is to help him learn the language, not to do his work for him and help him cheat his way through college | |
Re: [QUOTE=BEBELINDO;1178560]Hi i need an event handler method to let an user use the 4 arrow keys (up,down,left,right) from a keyboard input ... and also the letters "Y" for yes and "N" for no on the keyboard. [/QUOTE] ow key ... you need an event handler ... and your question is? … | |
![]() | Re: [QUOTE=OzY360;1179216]Hi, I am getting a rather odd error message when I try compile a java program. I have attached the original java code and a copy of the error message in a .txt file. Any help you guys can offer will be much appreciated.[/QUOTE] I'll help you by offering some … ![]() |
Re: you might want to indicate where it was thrown | |
Re: [Code=Java] String input = jTextField1.getText(); [/Code] you can pass this input variable on as a parameter, and you can store it for later usage. what exactly is your problem? | |
Re: you'll need to put a loop (for or while) in your code. a switch on it's own will not repeat itself for the other problem .. if you enter a number, it's either > 0, or <= 5 for instance: 17 is invalid, but still: 17 > 0 -2 is … | |
Re: you don't want to 'loop a question', otherwise, you'ld get the same question over and over. what you want, is to loop over a series of questions. just use the next basic logic: [Code=Java] String questions[] = new String[5]; // I assume you'll fill this in yourself for ( int … | |
Re: [QUOTE=purijatin;1165406]but then i did some changes in bin folder[/QUOTE] what did you change in there, and what for? | |
Re: you might want to check [URL="http://www.lmgtfy.com/?q=java+connect+to+derby"]this[/URL] | |
Re: 1. don't hide the screen 2. if you do want to hide the screen, you can always pas the data as a parameter 3. TURN OFF CAPS LOCK | |
Re: firstly, use Code tags, make your post readable. secondly: what exactly do you mean, output your JButton in a JTextField?? describe what you want it to do and what it is(n't) doing | |
Re: just take into consideration what you've seen in your courses, and decide how to put that into an distributed application. off course, putting in stuff your teacher didn't show you 'll get you good points as well | |
Re: also, you'll need to learn where to put your code .. that if structure should be within the main method | |
Re: [QUOTE=kawalya;1156811] In case you still have not solved your problem, [/QUOTE] when the thread-starter says: [Quote=Aisha25] thanks i fixed it [/Quote] it usually means: it's solved | |
Re: you don't actually use the values you decide within the switch, so how exactly do you expect them to change the outcome? | |
Re: [QUOTE=blazinhieu;1156786]my teacher didn't teach me that yet[/QUOTE] I'm quite sure you don't need your teachers help to find your way to Google or your course notes (if you have any) if you find Scanner to dificult, ain't nobody saying you can't use the JOptionPane class. you'll have an input screen … | |
Re: [QUOTE=JavaNewbieEK;1156621]To test the functionality of the rest of the program, I just have a single user name and password hard-coded in. It can not authenticate multiples. How the valid pairs should be saved is what I am wondering. 2 basic arrays, a 2-D array, linked list?[/QUOTE] imho the best way … | |
Re: analyse make a model program it test it improve it (repeat last two steps if necessary) hand it in | |
Re: [QUOTE=balajimarisetti;1150641]You used swing classes. So the code should be on the EDT(Event Dispath Thread). Try writing your code like this e.g [CODE] public static void main(String[] args){ EventQueue.invokeLater(new Runnable(){ public void run(){ // Write the Swing code here //you wrote it in the main thread itself } }); } [/CODE][/QUOTE] … | |
Re: [QUOTE=yasir iqbal;1156404]How to use delay function in turtle class in java,oop when drawing an object[/QUOTE] we don't know the 'turtle class', let alone whether or not it has a method to delay it. just try and look for info on the 'sleep(int i)' method, might help you out | |
Re: that might be because of the order in which you added the fields. since you're working with login and password, you might want to use: 1 JTextField 1 JPasswordField instead of two JTextFields | |
Re: [QUOTE=ksaihat;1155298]Hi kvass ammmm can you explaine it with the code[/QUOTE] Jwenting allready did that ... just google 'fibonnaci' and program it. don't just assume making your assignments is the biggest thrill or honour we're hoping to achieve here | |
Re: if it just has to close the application, why not just put: [CODE=Java]System.exit(0);[/CODE] | |
Re: looks great, but next time: try and post your error-messages. since the Random class does not have a nextInt method that takes an array of integers as parameter, I guess you must've had some. you may want to check this thread, though [URL="http://www.daniweb.com/forums/thread150711.html"]previous thread[/URL] | |
Re: so, if you do want to access it like that, declare it public. |
The End.