2,443 Posted Topics
Re: Also, that tutorial is bad in more ways than one (and not [i]only[/i] because it's causing an exception). | |
Re: Place a reference to the applet in an html page, obviously. [url]http://java.sun.com/docs/books/tutorial/deployment/applet/[/url] | |
Re: Did you mean maybe rs1.getString("Total"), seeing as how that statement [i]seems[/i] to be in the rs1.next() while loop. Also, you definately should [i][b]not[/i][/b] be doing this stuff as scriptlets in a JSP. This is a maintenance nightmare. | |
Re: [code] sed -n '$p' filename [/code] | |
Re: Java != JavaScript. They have similar names (purposefully done so by the JavaScript creators), and a somewhat similar syntax (again, purposefully done), but that's all. Next time post to a JavaScript forum. I have already requested that the admins move this one, so don't bother creating a new one there. | |
Re: Your question makes no sense. If you want to display a date in the default manner for the default locale for the machine on which it is running, simply use toString(). What's the problem? | |
Re: Come on now, show some effort. Show us what you have tried in solving those problems, and provide information about what is going wrong with them and we will help you correct them, but we will not do them for you. | |
Re: Use a new statement object to retreive the second resultset, as, as the API docs [i]clearly[/i] state, executing another SQL command on a statement object will automatically close all previously opened resultsets associated with that statement. | |
Re: You can also do [code] tar xvf bin.tar \*perl\* [/code] but you're right, the quotes are probably easier. | |
Re: Other than the fact that you shouldn't be doing this in a JSP, I don't know, since you haven't bothered to tell us what is going wrong with it, and I am not even going to attempt to guess. What exceptions do you get? | |
Re: You can't. You aren't opening it with Java either. You are simply telling the browser what is being sent (the content type) and letting the browser decide how to display it. In this regard, Java has nothing to do with it. Assuming that this question is related to [url]http://www.daniweb.com/forums/thread100436.html[/url] | |
Re: Write a servletContextListener to start the threads at application startup and interrupt them at application shutdown. [url]http://java.sun.com/j2ee/1.4/docs/api/javax/servlet/ServletContextListener.html[/url] | |
Re: [QUOTE=bloody_ninja;644958]How odd. As I stated before, I am using Java Eclipse SDK and within it says -JRE System Library [jdk 1.5]- and about 1/3 of the programs give me a compiler error. I talked to a programmer and my uncle's office and he said yeah, some things are different so … | |
Re: Create two small classes and have one class call new on another class (that contains all the things you want to see) and run through the instantiation in a debugger. | |
Re: So don't call setVisible(true) (show is deprecated). Really, as long as your frame isn't a instance variable (or even worse class variable) in a class that is always active, it will, eventually, be garbage collected as soon as it is has gone out of scope and been disposed. If you … | |
| |
Re: Uhm, I'm sorry but you're getting your terms mixed up. What you refer to as declaring the method, is actually calling the method, and what you refer to as defining the method is both declaring [i]and[/i] defining the method [code] public class A { public static void methodB (String c) … | |
Re: 1. [i]Not[/i] urgent. To suggest that this "problem" is more important than anyone else's problem here, and we should just stop everything and "help" you, and you alone, is just plain [i][b]rude[/b][/i]. 2. Post [i]your[/i] code and give a complete, but still brief, description of your problem (including all error … | |
Re: If your site is not a web container, you're going to have to make an Applet (and if you wrote a normal app, you'd have to do that anyway). [url]http://java.sun.com/docs/books/tutorial/deployment/applet/[/url] | |
Re: Post your code and we will help you correct it, but no one is just going to [i]give[/i] it to you. | |
Re: A JSP will [i]not[/i] play anything. If you know how to provide a browser with these items in HTML in such a way that the [i]browser[/i] will play them, then you do it [i]exactly[/i] the same way in JSP. You can also have a servlet behind a link that masquerades … | |
Re: That error means, that in that class you have no method called "appendToBannedIP" that takes a String as an argument. | |
Re: Not that I think you'll win much, but did you use the -9 option when you created the gzip file? Otherwise, split and join. | |
Re: And what exactly would be the problem, other than the fact that this is JSP and should have been posted to the JSP Forum, and you are doing about every thing in a JSP that you [i]shouldn't[/i] be. | |
Re: Question 1. What if the same pattern also fits inside the "largest" pattern? i.e pattern: A.*B String: [b]AB[/b]CDEF[b]B[/b]GHIJK Is AB matched, or is ABCDEFB matched? Question 2: What is th difference between 'A-Z' and '[A-Z]'? (Although there are other things in tr that [i]should[/i] be used for this.) Question 3: … | |
Re: After a certain amount of time (I believe 30 min) you can't anymore. | |
Re: Much easier, an ice-pick inserted about 3 cm into your ear in the direction of the other ear, pull it out, insert a flexible straw in its place, and you can blow your own mind. | |
Re: Not urgent at all to us. You retreive the InputStream from the response Object and use setBlob on a PreparedStatement to write it to the DB. | |
Re: No, do not use the JDBC-ODBC Bridge. Use the actual JDBC Driver whenever there is one available. @OP Have you configured your Windows Firewall to allow connections to that port? | |
Re: Uhm.... if (errcode != null) before the trim? | |
Re: Don't do other's homwowrk for them. It is against the terms and agreements you agreed to when you signed up here. And, if you absolutely must post code, [i][b]please[/b][/i] use code tags. | |
Re: [code] "\\+" [/code] instead of just [code] "+" [/code] and likewise for the rest. | |
Re: You shouldn't be "writing" to a DB from a JSP in the first place. | |
Re: Look at the web applications logs for a stacktrace and a better exception message. You should not be using scriptlets, however. Write a Bean. | |
Re: This is a servlet, not a JSP, and this sort of thing [code] out.println("<html>"); out.println("<head>"); out.println("<title>Servlet ReturnName</title>"); out.println("</head>"); out.println("<body>"); out.println(getName); out.println("</body>"); out.println("</html>"); [/code] is frowned upon these days in a Servlet. See [url]http://java.sun.com/javaee/5/docs/tutorial/doc/[/url] | |
Re: Well, are you using the equals method to compare the Strings or == ? Your code might help us to guide you better. | |
Re: Well, you could write a stop method and rewrite the "start" method to use threads, then after you instantiate the class, store it as a session variable, then start the "start" method as a thread. Then return a page containing the key used to store the object and stop button. … | |
Re: [QUOTE=bhavanivishnu;357309]Here I am giving a scenario to set class path suppose jdk is installed in c;/java/jdk1.5 then follow the below three steps to set class path set JAVA_HOME=C:\Java\jdk1.5.0_07 set path=;%path%;%JAVA_HOME%\bin set classpath=%classpath%;%JAVA_HOME%\lib\tools.jar[/QUOTE] If Java is installed in [inlinecode]c:/java/jdk1.5[/inlinecode] (and I am assuming it is [b]c:[/b] and not [b]c;[/b] as posted) … | |
Re: Lets see if you can see the problem. Here is a snippet of your code [code] public class ChessBoard ... { public Chessboard() { ... brd = new GridChessBoard(); ... } } public Class GridChessBoard extends ChessBoard ... { public GridChessBoard() { ... } } [/code] See the problem? If … | |
Re: Well, what's wrong with this post. Let's count the ways: 1. You use a bad title (you can use Java to search a MySQL DB, but you can't use a MySQL DB to search Java). 2. You dump a bunch of unformatted into the post (because of a very poor … | |
Re: What is that trim suppossed to be doing? a number entered like that is an int, which can't be trimmed, and getDate returns a Date, which can also not be trimmed (if that was what you meant). Neither of those are Strings, which is the Class that actually has that … |
The End.