4,084 Posted Topics

Member Avatar for sp85202

can you show your entire code? it's possible you didn't initialize your ArrayList correctly or in the right scope, also there might be something wrong with the input. can you also show the complete stacktrace you get when you get that nullpointer?

Member Avatar for stultuske
0
237
Member Avatar for LFCFan_07

when you click your button, you're not going to perform the actions in the ClickButtonClass because you are not adding that kind of Listener to the Button. let your ClickListener class do the action you want to perform and you'll need to take a closer look at how to build …

Member Avatar for mKorbel
0
2K
Member Avatar for CityThrille

well, it appears there's something wrong with the file you're trying to copy. just trying again won't solve the issue I'm afraid, you may have to go back to the original source (hope for you that isn't the not back-upped original of your file) and download it again, or copy …

Member Avatar for rubberman
0
276
Member Avatar for Hypnos_16

a : is something being mentioned, it's not an actual error that will block your program b : what error do you mean? can you show how you tried with params and what error message you get? c : input what code? is that how you start your app, a …

Member Avatar for Hypnos_16
0
229
Member Avatar for T4gal

maybe you should ask the people at GoDaddy, since they are handling your dns and hosting?

Member Avatar for chrishea
0
450
Member Avatar for MxDev

as Ztini said: experience beats certification. if you do want to take the exam, there are no guarantees whatsoever. the only thing you can do is: - know the material covered by it - prepare for the exam (for instance: don't keep camming until 5am the day you're going to …

Member Avatar for MxDev
0
96
Member Avatar for riahc3

how do you try to run it? what's in your main method? what error message do you get? if you are trying to run one of the above classes, it will fail because there is no main method in them.

Member Avatar for riahc3
0
399
Member Avatar for tartosha

what help do you need? you know what to do, the only thing you need to actually create and test that application is a keyboard, and since you've been able to write that post, I 'm pretty sure you already have one. show us the code you've written and where …

Member Avatar for stultuske
0
213
Member Avatar for wallet123

you've called your audioplayer MGP, but you call the start method on MPG, that's why it doesn't find that one. the other error, I'm not really sure about, I've never used that class, but it looks like you're calling a class from outside the scope where it can be called, …

Member Avatar for TIM_M_91
0
243
Member Avatar for sadiaali

well ... being bad at mathematics doesn't mean you can't make it as a developer (unless of course you decide to go writing mathematical applications). but logic, kind-a important. go check for logical puzzles, try to solve them, and then try to find a better way to solve them. if …

Member Avatar for stultuske
0
129
Member Avatar for jayadan

well, if it doesn't do what it 's supposed to do, probably corrections are needed. do you get wrong output, does your application crash? be a bit more specific. also, don't do: [Code=Java] try{ // your code } catch(Exception e) { } [/Code] you are just hiding the error message, …

Member Avatar for stultuske
0
277
Member Avatar for jayadan
Member Avatar for fatooma92

[QUOTE=fatooma92;1774777]i need someone to do this program for me and before saying that i have to do my homework alone i had midterms all week and in about in hour or so and i forgot about this assignment and i just dont have time so plz help here it is …

Member Avatar for jbennet
-1
170
Member Avatar for ilovejava
Member Avatar for MicroD

read every line as a String for each String you want to parse, you can either write a regex to find the inner part, or you can calculate the indexes and use the substring method

Member Avatar for stultuske
0
116
Member Avatar for davy_yg

just google for 'jQuery menu'. you'll find tons of easy-to-implement scripts to do just that.

Member Avatar for stultuske
0
71
Member Avatar for Webmastergrace

well ... a good way to start is: add informative contents. best with starting to provide information about one subject, you know a lot about yourself. just copy-pasting wiki-entries without knowing for yourself whether or not the article is in fact correct, or just a pile of 'blabla' compiled by …

Member Avatar for torbatt
0
195
Member Avatar for softDeveloper

don't just hand out code. checking whether or not a number is a prime number is very easy, and there are tons of threads about this already, not to mention the milions of examples online. giving him the code when he's not even doing the effort to try, or even …

Member Avatar for softDeveloper
0
282
Member Avatar for Kert

how is this: Exception in thread "main" java.lang.Error: Unresolved compilation problem: Type mismatch: cannot convert from Object to int. not clear? you are trying to convert an Object to a primitive dataType, of course that doesn't work.

Member Avatar for DavidKroukamp
0
214
Member Avatar for Pravinrasal

[Code=Java] Object[] row = new Object[3]; for ( int i = 0; i < 3; i++) row[i] = readObjectFromDB(); [/Code] if you don't know up front how many items there will be, use a List or a Collection. is your key stored in the DB?

Member Avatar for stultuske
0
133
Member Avatar for Syrne

toString() returns a String representation of the Object it's called upon, or, if you have that code exactly, the toString method from within that same class. (Object) just parses that what follows to the type Object. since a String (and actually every Java Object) will pass a is-a test when …

Member Avatar for peter_budo
0
757
Member Avatar for cmps
Member Avatar for cmps
0
126
Member Avatar for riahc3

we're not in this for the glory, we're doing this because we like to do this ourselves :) you can also notice that a lot of people say thanks in the original thread, so not posting here is not the same as being rude. for a lot of those who …

Member Avatar for stultuske
2
85
Member Avatar for maverick420

I can't find a TextBox or jTextBox in there. what field are we talking about?

Member Avatar for maverick420
0
155
Member Avatar for johny08z378

what do you mean by a variable? your String itself is a variable. if you want to create a File object named after that String: [Code=Java] String ss = "file1"; File myFile = new File(ss); [/Code] slight remark: the above will just create a File variable, not an actual file …

Member Avatar for NormR1
0
115
Member Avatar for dav555

have your application run on your server, and check the logs on a regular basis. I don't really understand what it is you're trying to do: an application that runs at the clients system and the logfiles go to you?

Member Avatar for stultuske
0
143
Member Avatar for riahc3
Member Avatar for BeginningJava

why are you asking for a filename, if you are going to use a hardcoded one? also: you are reading the charAt from the filename your user entered, not from the file you're working with. your max is based on the length of the contents of File1.txt, but you are …

Member Avatar for stultuske
0
372
Member Avatar for sheushen

yes, you can create a method in your GPA class which take the array as parameter and then print it, but that is very bad OO design.

Member Avatar for stultuske
0
214
Member Avatar for sanidon

pati[i].setdata(); since pati[i] is still a null value, you'll have to begin with: pati[i] = new Patient(); // or other constructor, anyway, you can't (shouldn't) call methods on a non-existing instance of an object.

Member Avatar for richieking
0
202
Member Avatar for wallet123

JFrame has nothing to do with JOptionPane. a JFrame can be used to create your own user screens, so yes, also a 'dialogbox' with as many input fields you need, in the layout you want it to be shown in. [URL="http://docs.oracle.com/javase/tutorial/uiswing/"]This[/URL] would be a good place to start learning how …

Member Avatar for wallet123
0
120
Member Avatar for nickliutw

well ... I'm not sure why you make a palindrome check this complicated, but anyway.. I think either you didn't think your logic out straight, or you 're mistaken about what a palindrome is. also: what ArrayQueue class are you using? all you really needed to do is: iterate over …

Member Avatar for nickliutw
0
164
Member Avatar for mjselkirk

well .. what do you think your setters and getters are for, if not to exchange information between several classes?

Member Avatar for NormR1
0
158
Member Avatar for codemonster

that's a wee bit hard to see, if you don't show any code, nor how you try to update your code or where you want to update it. in a JTextField, in JLabel, ...

Member Avatar for codemonster
0
214
Member Avatar for Hussam Alahmadi

I'm not going to go through an attachment, is i that much trouble to copy paste your assignment in this thread along with your code?

Member Avatar for stultuske
0
113
Member Avatar for vishnukumar

what you are doing has nothing to do with actual programming, you're just trying to do everything without the programming, which is why you don't have any control over it, and why you don't know if somethings going wrong, and, if so, what. try hardcoding the setting of values in …

Member Avatar for stultuske
0
482
Member Avatar for scru

well, if you want to work for yourself, you have to be able to deal with some extra costs. for instance: what if you do have a project, but the payment from your client arrives a few months later than expected? sure, in a perfect world that would never happen, …

Member Avatar for stultuske
0
117
Member Avatar for adil_bashir

how hard do you think it is to write that? try, and within about ten minutes there will be one.

Member Avatar for stultuske
0
60
Member Avatar for MichaelCJ10

well, why wouldn't you be able to use a double as a counter? and converting an int to a double? what good whould that do? you would have decimals, yet, but since every value stored in an int is always rounded (since it has no decimal capacity) all your prints …

Member Avatar for stultuske
0
301
Member Avatar for makehaste

did you enter a value in all the input fields you are trying to get a value from?

Member Avatar for makehaste
0
299
Member Avatar for syfr

looks to me like your tour_guide variable in holiday is of the type 'Person' so you'll have a private Person tour_guide; in your Holiday class, and the mutators (setter and getter) to set and get the values.

Member Avatar for syfr
0
445
Member Avatar for libran

[QUOTE=sambhu singh;1772398]i want to knw like how it will read the text file application.txt? and i'm try to run this exm in eclipse but cannot how to ?[/QUOTE] write your own code, there are examples enough on the forum to help you out. this thread hasn't been posted in for …

Member Avatar for stultuske
0
1K
Member Avatar for shootingrubber

static: class scope. instance variable: instance scope. if it's not a static variable, it's an instance variable. they can only be reached through an instance of the class, so can only be accessed if an instance is created. if you set the value for an instance variable, you set it …

Member Avatar for stultuske
0
150
Member Avatar for TrickyT

nope, it's a bit the "no pain, no gain" scenario. using Windows/Linux is supposed to be quite easy for the user, but try to write one from scratch, that'll be a bit harder to do. look at the first link mKorbel provided you with, that's your best place to start …

Member Avatar for stultuske
0
155
Member Avatar for jadeplaza

and never just copy what you see in a 'youtube-tutorial'. every dimwhit whit a webcam or screen capturing software is able to make so called 'professional tutorials', that doesn't mean they're actually any good. all you need to know is how to create a basic Swing GUI, for which you …

Member Avatar for stultuske
0
215
Member Avatar for raym.mart

you probably used wrong casing (upper-lower) to name your files. two remarks: instead of throwing a ClassCast exception in your compareTo method, just return false (that is the expected behaviour) and, don't allow your main method to throw an Exception. if need be, put a try-catch block inside your main …

Member Avatar for raym.mart
-1
251
Member Avatar for wonderlandslost

your first problem: in your ArrayDrawer, you have this method: [Code=Java] addTriangle(Triangle z) [/Code] but when you call it, you pass a double as parameter, not a Triangle. since a double is not a Triangle, your compiler can't process it. for your print problems: [Code=Java] /** * Print out the …

Member Avatar for NormR1
0
254
Member Avatar for affordacall

even if it were possible, it would run on the server where you have your exe stored, not on the client where you want the exe to be executed.

Member Avatar for jalarie
0
198
Member Avatar for MohEzzat

and how will your code while running know what to filter out? it must have a list of words stored somewhere. whether they're hardcoded or entered by reading them from an inputfile, you can still use the contains method. whether you have: [Code=Java] if ( text.contains("myWord")) [/Code] or [Code=Java] String …

Member Avatar for stultuske
0
192
Member Avatar for jackbauer24

package everydayUse.Print; here you are saying that your Print class is inside the package everydayUse.Print; but you are not importing a package named everydayUse anywhere.

Member Avatar for NormR1
0
110

The End.