@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info
Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2 3 4



Comments:

<0> hi all
<1> Talden what do i need to import to get TableSorter to work?
<2> Java is great.
<1> =)
<1> http://rafb.net/p/drLStq80.html
<2> Programming is marvellous
<1> Java.lang.ArrayIndexOutOfBound***ception: 10
<2> raki: nice code.
<1> p.length = 10, p[0].length = 7
<1> why does it go out of bounds?
<3> raki: your 2nd for loop...look
<3> it's increment i++
<3> it should be j++ right?



<3> also don't use == to test string equality
<3> use equals method
<1> ah
<1> yes
<1> true on both
<1> typo on the first , sloppy on the second
<1> thanks for spotting it :)
<1> i was clueless
<1> LtWinters
<1> i ended up with a nullpointer instead lol :(
<3> look at your first loop... p.length
<1> mhm?
<4> You're using p[0].length instead of p[i].length. If you really want to explicitly ***ume it's a fixed value for all rows I'd extract that value and use that.
<4> In addition p instead of posts... hmmmm
<3> there...
<1> i mean, it returns the position
<3> tired of looking at the code though
<3> hehe
<1> its the ListAppGUI that causes the nullpointer btw.. not the method itself X)
<1> whats wrong with using p intead of posts?
<1> =)
<4> You evaluate the length of p and then get the value from posts... so why p*** in p at all.
<1> oh..
<1> lol, then its a typo
<4> I have to ***ume that's an edit of the real method... the found value isn't used either.
<4> What if there are two matches? Which one are you wanting found?
<4> if it's the first you should be breaking the loop after finding the match... if it's the last you should be searching backwards and breaking the loop
<1> Talden, its an edit..
<1> its going to return int[] later,
<1> and then use a premature return..
<1> well, ur goin to be able to search next, or stop..
<1> something like that..
<4> In which case I'd return a SearchState that indicated whether more searching was possible and enclosed the match. much simpler management
<1> why not just have a dialog asking if they want to search for next inside the loop and then return if they dont?
<4> Separation of searching logic and UI
<1> see ur point..
<1> main task now is finding the nullpointer though
<4> Also a lot of the framework would be reusable for different search types.
<1> ya
<1> and thats main principle of oop
<1> i found the nullpointer..
<1> =)
<1> empty fields in the table =)
<1> need to check if length < 1
<1> hmm no wasnt enough hmm
<1> ah, had to check for null before doing the .length() ofc, thanks alot once again Talden
<1> ur an angel =)
<1> Talden u got time for one more question?
<1> oi!
<1> previously i used Arrays.sort with an added exception that "---" should be considered as highest possible value, so that those strings were placed in the end..
<1> now when i use TableSorter
<1> i dont know how to get the same result..
<1> do u have any idea on how to make it do that again?
<4> I'm afraid I don't do any java GUI work so I don't know the framework that well.
<1> http://rafb.net/p/BiCK3W88.html
<1> thats how i sorted before..
<1> including the "---" exception
<1> http://java.sun.com/docs/books/tutorial/uiswing/components/examples/TableSorter.java
<1> thats the TableSorter cl***
<1> i could just change that file ofc..



<4> Ahh well... good luck.
<5> is somebody available?
<6> hi i need to write a method that has two string parameters and returns the larger of the two
<6> im just not sure how to make the parameters.. i mean i have: if s1.compareTo(s2) > 0 {max=s1;} else {max=s2;}
<6> but what do i put before?
<7> s1 and s2 would be your parameters
<8> morning all
<1> good morning
<1> can anyone tell a tired soul how to change the spacing of the contents in a JTable, TableModel, TableSorter..
<1> so that the text isnt so close to the edge that is
<9> hey, i need to print a "pyramid" of *'s x units high using nested for statements, could someone help me out?
<9> http://www.eugeneciurana.com/pastebin/pastebin.php?show=2142
<8> ERICwithanH - we are not helping the HW
<9> heh, okayyy. and how come?
<9> asking for help is an essential part of learning
<8> actually doing HW is essential part of learning :P
<9> yeah, and i'm doing it.
<9> so, anyone else? possibly?
<1> MbGone
<1> i got an Object[][] that i need to fit into String[][],
<1> hmm
<8> fit into? as in copy?
<1> yes
<8> and the values in the Object[][] are Strings?
<1> String[][] str..
<1> Object[][] data = str
<1> getData(); { ..return data; }
<1> str = getData(); doesnt work
<1> found : java.lang.Object[][]
<1> required: java.lang.String[][]
<8> you need to cast it
<1> cast what?
<8> the data which is retured by the getData method
<8> not sure what exactly you are trying to do though
<1> MbGone i need to get the data[][] back into the string[][]
<1> MbGone help me =)
<8> raki - doahh, but why are you p***ing to the object[][] and then back to string[][] ? , anyway str = (String[][])getData();
<1> because i p*** it to the TableModel that uses Object[][]
<1> and then save it as strings
<1> so at the end i need to get it back into strings :)
<8> k
<1> MbGone whats "\?" thignei for blank space?
<1> nvm
<9> Why am I even taking Java as an industrial design major?
<8> you will have to answer your own question
<9> so, you want to help me, yet?
<10> moin :)
<8> ERICwithanH - i told you that we are not helping with HW
<8> hey Clackwell
<9> i still don't understand your reason, and, frankly, it is moronic.
<9> heh
<9> *reasoning
<10> ERICwithanH: feel free to ask java related questions. no homework please.
<9> it's java homework
<10> ERICwithanH: as i said, feel free to ask java related questions. no homework please.
<9> but the only java related questions i have are ***ociated with my homework
<9> so, basically, ask nothing at all.
<10> why do you insist on telling me that you have homework when i keep trying to motivate you to ask java questions?
<9> well, because... you see, i am taking a java cl*** and if i weren't taking a java cl***, i wouldn't have java related questions. but, because i am taking a java cl***, i have homework, thus the only java related questions i have are directly linked to my homework, and you said no homework.
<10> able to, rather
<11> Talking about yourself in third person? ;)
<11> Maybe the power is going to your head ;)
<9> okay, so... i need to build a "pyramid" x units high using only loops and nested for statements, but i am having difficulty doing so..
<10> ERICwithanH: no clue about that. maybe the question is too unspecific. it sounds like "please, someone tutor me".
<10> in my experience you hardly ever get that on irc.
<10> maybe this is just a matter of wrong expectations.
<10> ERICwithanH: consider working with your co-students and asking the professor, ***istant, lecturer. those are the most likely to know exactly what you are coping with.
<10> and thus it makes sense to ask them, not foreign people.
<9> heh
<10> !testcase ERICwithanH
<12> ERICwithanH: The SSCCE - Short, Self Contained, Correct (Compilable), Example: http://www.physci.org/codes/sscce.jsp (mirror: http://javafaq.mine.nu/lookup?364)


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #java
or
Go to some related logs:

#mirc
#linux
how gtalk use comet
#chatzone
WHO WAS FOND OF SAYING 'I WILL GLADLY PAY YOU TUESDAY FOR A HAMBURGER TODAY
#networking
bd-70g
k3b preformatting+rw
#linux
#apache



Home  |  disclaimer  |  contact  |  submit quotes