754 Posted Topics
Re: Store the data in a mysql database so that you can do searches, and using php you can display dynamic pages. Then just organize the data you pull from the database into html tables. | |
Re: That's how AOL's protocol (TOC) works. String msg = "this is a message"; //write it out out.writeBytes(msg); //recipient reading back in byte[] bytes = new byte[in.available()]; in.readFully(bytes); String incoming = new String(bytes); | |
Re: I see most computer-related forums using phpBB. I made my own forums, so I selected "other". You can take a quick look at what I have published so far, but current version is still on my pc. (its in development) << url snipped >>[url="http://kff.dbspot.com/forums/"][/url] I know, doesn't do much currently. … | |
Re: For getting a file, you could take a look at JFileChooser. [code] String input = "a line from the file"; String word = "key word to search for"; int occurrences = 0; int index = 0; while ((index = input.indexOf(word,index)) > -1 && index < input.length()) { occurrences++; index += … | |
After a form is completed its submitted to another page to process the form. Once that's done, it forwards back to where visitor was. I want to display a message to the visitor first before moving to the next page, so how can I delay the page forwarding? | |
Re: [quote]So what is the solution to the following:[/quote] That isn't a question, that's you wanting us to just solve the homework for you. And it isn't going to happen. So again, whats your question? | |
Re: First of all, you're passing 1 to the private method instead of K. I have no idea why you have a public method call a private method that does the exact same thing anyway. And how you're figuring the total count of nodes at a certain level makes absolutely no … | |
Re: There's always MD5, if you never have to recover the readable password again. | |
I'm using a JEditorPane and StyledDocument, which automatically wraps text to the window. I cannot have this, I need the window to allow horizontal scrolling of the text. I've been all over yahoo and google and cannot find an answer on how to disable word wrapping. And before anyone tells … | |
Re: Perhaps you should send the entire post to Geshi to be highlighted. Parse your text, find whatever is inside the code tags, then send only that text to be parsed with Geshi. | |
Re: You can clear this warning by not using the method it says is deprecated. It basically means the method is no longer the preferred way, and it may be removed in future releases of jsdk. | |
Does anyone know how the compareTo() in TreeSet is implemented? I needed a sorted list of String elements and was going to use a binary chop method to find if a search key was in the list. Is this how the TreeSet does it already? Reason I'm asking is because … | |
Re: Not sure if this'll tell you want you need. [URL="http://java.sun.com/developer/onlineTraining/Programming/BasicJava2/socket.html"]http://java.sun.com/developer/onlineTraining/Programming/BasicJava2/socket.html[/URL] There was a different tutorial I was trying to find that helped me out a lot on networking, but I can't seem to find the link. | |
Re: We can help you out, but we're not going to do your homework for you. Give it a try yourself first, then when you get stuck you can ask us specific questions about your problems. | |
Re: I don't believe you can, sound cards don't use different ports for speakers and headphones. Plug in headphones and I'm pretty sure the speakers get shut off. | |
Is there a way to set the number of spaces shown for a tab? (tab as in a tab character) I've made an editor using a StyledEditorKit and StyledDocument, but tabs give more spaces than I would prefer. | |
Re: [URL="http://java.sun.com/docs/books/tutorial/uiswing/components/dialog.html"]http://java.sun.com/docs/books/tutorial/uiswing/components/dialog.html[/URL] | |
Re: plextor is great. I've been happy with my TDK single layer. | |
Re: [QUOTE] just got stack at one question [/QUOTE] Unless you're from the far south, its STUCK! You've written stack 3 times now, a little bit passed a simple typo! As for help, we're willing to help anyone who's willing to try. Ok, so you did the other problems on your … | |
Re: woh, its lunch time so I'm not reading that novel. (but i'll skim it for an actual question) [QUOTE] I need some hints to solving my problems [/QUOTE] It'd help if you told us the actual problem you're having, rather than post the entire assignment. | |
Re: This is the 3rd SMS post this week. Why don't all of you go off and do your homework together. | |
Re: [code] String Filelocation = "c:\\temp\\hello.txt"; //get the size of the file long length = Filelocation.length(); [/code] Get the size of what? File? Looks more like a String to me. A 16 character length string to be exact. Try this instead: [code] long length = is.available(); [/code] | |
Re: Visit the forums at gamedev.net, there's a java section. | |
Re: I suggest you go read up on programming basics. You know how to retrieve an element from an array? int x = myArray[index]; To make sure the index value is within bounds of the array, make sure the index is between 0 and array.length-1, inclusive. | |
Re: Be specific in your questions. What error are you getting? | |
Re: A simple 2D array can make this easy. boolean[][] grid = new boolean[8][8]; When the queen comes a square, update the array. grid[x][y] = true; Then when you draw your squares: [code] for(int Row=0; Row<8; Row++) for(int Col=0; Col<8; Col++) { if (grid[col][row]) //g.setColor(highlight); else g.setColor(Pos_Color(Row, Col)); g.fillRect(left1+Col*SqWidth, top+Row*SqWidth, SqWidth, … | |
Re: int a = ? int b = ? System.out.println("Addition: "+(a+b)); System.out.println("Subtraction: "+(a-b)); System.out.println("Multiplication: "+(a*b)); System.out.println("Division: "+(a/b)); And if the user input is a string: int a = Integer.parseInt(value); Now what's confusing? | |
Re: [quote]I suspect buzzle.com has one database in which each entry has a type atribute (chapter, article or link)[/quote] I thought the same thing. Alternatively though, you could connect to each database separately and perform the same query. | |
Re: Senior project, no one here will give you codes. The whole point of it is to get you to figure it all out. Hopefully, you haven't waited until the last week to do it. This library should let you connect with a usb modem I believe. (unsure, never used it, … | |
Re: sounds more like you just made a windows batch file | |
Re: Who would pay someone with no programming experience to code such a simple problem? Same basic code as iamthwee posted, except for a small change. [code] int[] array = {45,89,65,52,5,68,7,2,24,17,35,84,65,99,54,32,7,66,98,15,35,45,65,75,37,15}; for (int i=0; i<array.length; i++) { int temp = -1; for (int j=i; j<array.length; j++) { if (array[j] > temp) … | |
Re: Take a look at this example, it might help you see what you're doing wrong. I'd look through your code, but I dont feel like getting a headache staring at unformatted code. Use code tags next time. [code] //determine number of rows from search result $row_count = //whatever //how many … | |
Re: There's not problem with that. The main trouble you'll have with applets though is access privledges and making sure the server the applet is running on allows it to connect to other ports and addresses. Unless of course, the client applet and server are hosted on the same machine. | |
I want to add theme support to my program so that users can just download jar files containing a LnF and just drop it into an extension directory or whereever. I'll just scan that directory for jar files to see which are present. Is there a way search for a … | |
Re: It'd help if you described to us whats not working. Whats the intended affect? whats it doing instead? Can you just not read the file back in, or is it that you cant get it to display? | |
| |
Re: Well whats the problem you're having? Don't just post your homework problems and say fix it, you'll never get anyone to help that way. | |
The probably isn't the parsing actually, I can't even get to that part yet. The webpage uses a different character set, "windows-1252". But even after setting the reader to use that charset (which exists in the system), I still get the ChangedCharSetException. [code] String link = "myurl.com"; URL url = … | |
The object I use to create a Transferable object with is the same object I should get on the drop component, right? All I want to do is drag a row from one JTable onto another JTable. I don't want to copy the data, only send index number of the … | |
Re: Read the API [url="http://java.sun.com/products/javacomm/reference/api/index.html"]http://java.sun.com/products/javacomm/reference/api/index.html[/url] Here's a small example [url="http://java.sun.com/products/javacomm/reference/docs/API_users_guide_3.html"]http://java.sun.com/products/javacomm/reference/docs/API_users_guide_3.html[/url] That package appears to only be for serial and parallel ports rather than modems. | |
Re: Haven't tested, this is just a guess. I don't know if an rtf document will display html as plain text or not, but you can try. [code] String html = "<b>hello world</b>"; Reader reader = new StringReader(html); RTFEditorKit.read(reader, document, pos); [/code] | |
Re: What's really sad is that I may have to work with people like this some day. | |
Re: [url="http://java.sun.com/javase/6/"]http://java.sun.com/javase/6/[/url] dunno if what you want is on there or not | |
Re: I think he just wants to send a file, say from a work computer, to his home pc, but doesn't want to do any actual work himself. | |
Re: hahahahahahaha. Here's a hint, do your own homework. I can't imagine a beginner java book that wouldn't even cover what a super class is. If all else fails, google. I will give you a hint though, #13 depends on what java version you're using. | |
Re: what kind of a webmaster knows absolutely nothing about html? html and php files are both just plain text. Simpley change the extension from .htm to .php. | |
Re: Here are the drivers of Oracle for java. [url="http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html"]http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html[/url] Install the jar into the "\jre\lib\ext\" directory of wherever your jsdk is installed at. This code would print out the database names on the server: [code] Class.forName("oracle.jdbc.driver.OracleDriver").newInstance(); String url = "jdbc:mysql://192.168.2.184/"; String user = "guest"; String password = "guestPass"; connection = … | |
Re: board sounds bad to me. Is it just the bios freezing up? Does it freeze if you dont push delete and try to boot normally? | |
Re: My guess is something screwed up big time and everything reset itself. Just create a new user and grant privileges. | |
Re: have you tried searching google? I believe the first result I got was from mathworld explaining the whole equation. |
The End.