2,777 Posted Topics

Member Avatar for valatharv

I've never tried it. What happens when the Monitor class does a System.exit() after starting a process? Is the process ended also?

Member Avatar for valatharv
0
14K
Member Avatar for pi_lord12

Please open the browser's Java console, copy the contents and paste it here. Remove the package statement or change the <APPLET code= to include the package name and move the html to the folder with the drawboard folder in it. Ie up one level. The applet code doesn't have any …

Member Avatar for pi_lord12
0
120
Member Avatar for ceyesuma

Could you define what you mean by 'table'? That's sort of a generic word.

Member Avatar for NormR1
0
76
Member Avatar for miraj0072004

If something needed is missing, I guess you need to find the missing part.

Member Avatar for NormR1
0
68
Member Avatar for jakx12
Member Avatar for Krefie
Member Avatar for jt86442

I read the API doc for writing PDF files to see what the options are. Not part of standard java.

Member Avatar for NormR1
0
71
Member Avatar for SimpleIntellect

[QUOTE]StackOverflowError[/QUOTE] Those usually occur when there are recursive calls in the program. Is knap() calling knap() too many times? Put in a counter and use println() to show what is happening.

Member Avatar for NormR1
0
162
Member Avatar for j_kathiresan
Member Avatar for chris evans

Accumulate the text inserting newlines or use an append() method to add to the end.

Member Avatar for leverin4
1
145
Member Avatar for bryan69

Please use the code tags when posting code [QUOTE]bufRead.readLine().equals(t.toString()[/QUOTE] Try debugging your code by Displaying the value of every line you read and the value of the String t.

Member Avatar for NormR1
0
1K
Member Avatar for iskalabatoto

First write a program to read an integer from the user. Then add a loop to print out '*'s from 1 a line to the number per line. See println() and print() for doing the output. Type in your code, compile it and execute it. Come back if you need …

Member Avatar for peter_budo
0
215
Member Avatar for deiago

One way is to add a method in the class with the data that will return the data. Then pass a reference to that class to the class that needs the data where it can be called. In the class with the textfield: tf public String getData() [ return tf.getText(); …

Member Avatar for deiago
0
254
Member Avatar for Illidanek
Member Avatar for NormR1
0
637
Member Avatar for yapaarachchi

Another approach is to use the full path to the command when using it so the OS doesn't need to look on the PATH for it. On some OSes you could write a script or batchfile that has the full path in it.

Member Avatar for leiger
0
119
Member Avatar for newbeejava
Member Avatar for TheWhite

[QUOTE]able to add words to a pane that are different sizes and fonts.[/QUOTE] Look at the JTextPane class. [QUOTE]requirement of being able to look back at previous lines and fetch the text without formatting[/QUOTE] What are you going to do with the fetched text? Hold/process it as a String?

Member Avatar for JamesCherrill
0
95
Member Avatar for gailross

Can you post the full text of the error message? The error message should have the source code line number in it. You've left that off when you entered the error message. Also use code tags when posting code to keep its formatting.

Member Avatar for leiger
0
157
Member Avatar for pi_lord12

The constructor must have the SAME name as the class. Line 8 has a different name. Lines 3 & 8 have the same names in second code.

Member Avatar for pi_lord12
0
2K
Member Avatar for Virux

Please copy and paste the full text of the error message. There could be important info there. Is the class in a package?

Member Avatar for NormR1
0
378
Member Avatar for daudiam

For questions that ask: "What will happen if ..." I recommend you write a program, execute it, look at the output and see happened.

Member Avatar for daudiam
0
297
Member Avatar for ceyesuma

[QUOTE]is txt actually a new JTextField() if the name is changed[/QUOTE] No. The name belongs to the Component class a parent of the textfield class. The textfield object is the same object created with the new statement. [QUOTE]Is it possible to get unique txt.getText(); from txt fields if the txt.setName() …

Member Avatar for ceyesuma
0
85
Member Avatar for nestensity

[QUOTE]Cannot make a static reference to the non-static field[/QUOTE] Looks like you are trying to reference variables from the static main() method that only exist when an object is created. The variables do NOT exist until you do a new GradeBook(). Once there is an object, you'll need to use …

Member Avatar for NormR1
0
162
Member Avatar for 1x4n

if((fptree_id[b].equals(item)) && (fptree_pid[b].equals(temp_pid))){ I assume your error happens here. Check your logic to see what that the value of b is valid. Use some println() to show the value of b and the value of any other variable that could effect how the loop works. The for loop allows b …

Member Avatar for 1x4n
0
134
Member Avatar for iamcreasy

Creating an array only creates the array object. There are no Animal objects in it yet. You need to fill the array with Animal objects, element by element.

Member Avatar for NormR1
0
104
Member Avatar for srinivas88
Member Avatar for joverlyanne

Hard to help you without any code to look at and questions about the code. What is/are your questions?

Member Avatar for NormR1
0
89
Member Avatar for nestensity

What is the program supposed to do? There is a lot of code with no comments explaining why your are doing things. Add comments to describe what each section of code does. Where is the printing of valueq1? Why do you think the output from your program is wrong? What …

Member Avatar for NormR1
0
151
Member Avatar for Zhoot

[QUOTE]My program will not start once I try to execute the Jar file[/QUOTE] What error messages do you get? Copy and post them here. How are you executing the program outside of the IDE? Open a command prompt and execute it there so you'll see any error messages: java -jar …

Member Avatar for NormR1
0
101
Member Avatar for zyaday

What does the audio object's class's API doc say about that error message? Is this a compile time or execution time error? Your a little short on explaining what your doing.

Member Avatar for NormR1
0
193
Member Avatar for kdmuk10
Member Avatar for NormR1
0
123
Member Avatar for prem2

[QUOTE][url]http://ipaddress/HelloWorld/src/HelloWorld.java?type=1[/url][/QUOTE] This url looks like it points to a java source program. I would expect that the server would read the source file and return it to your browser. If you want to execute your servlet, you need the URL that points to that servlet.

Member Avatar for stephen84s
0
99
Member Avatar for ttboy04

There is nothing in Random that says that it can not return 2 equal values back to back if the range of numbers it's returning is so small. If you want 2 sequential numbers to be different, save it, compare against the last and get another one until its different.

Member Avatar for aspire1
0
138
Member Avatar for redZERO

[QUOTE]I have no idea how the program will deal with the path (C:\\My Documents) to the document on the other computer.[/QUOTE] The "magic" that makes the internet work is servers. To communicate with another computer, that other computer needs some software running to receive your messages. That software is called …

Member Avatar for NormR1
0
162
Member Avatar for nestensity

That's strange. Line 52 in the error message is blank in the code you posted. What does the method slots.get(i) return? Is it an object with a method: inputData()? Break up the compound statement into separate parts and println() the results of each part. Compound statement has more than one …

Member Avatar for stephen84s
0
130
Member Avatar for rukshilag

[QUOTE]check whether a solution exists[/QUOTE] Could you define what a solution is? How are the numbers to be partitioned? Sounds like you need an algorithm for solving the problem? What do you have so far?

Member Avatar for thamilvaanan
0
578
Member Avatar for MPQC

[QUOTE] I need to make it be able to find multiple modes[/QUOTE] Can you explain what that means? One way to count occurrences is to use a hashtable with the key = an occurence and the value = the count.

Member Avatar for MPQC
0
2K
Member Avatar for Umar Ali

[QUOTE]it doesn't work[/QUOTE] please explain and show error messages or describe what's not working.

Member Avatar for NormR1
0
104
Member Avatar for stmartin
Member Avatar for vs.vaidyanathan

When you get errors, please copy and paste the full text of the error message here. Don't edit the error messages.

Member Avatar for NormR1
0
261
Member Avatar for chris evans
Member Avatar for NormR1
0
2K
Member Avatar for beforetheyknew

An applet can write to the browser's Java console. That's useful for debugging. There is no way for an applet to read from the console. You're going to have to learn a little GUI to get input from a user.

Member Avatar for NormR1
0
72
Member Avatar for gabec94

[QUOTE] it refuses to open[/QUOTE] Do you get any error messages? Please copy and paste full text here. Does your jar file have a correctly formatted Manifest file?

Member Avatar for gabec94
0
156
Member Avatar for mitch9654

[QUOTE]it goes kablooie[/QUOTE] What does that mean? Please show the full text of any error messages. [QUOTE]FileOutputStream("http://mitch9654.zymichost.com/songs.DAT");" [/QUOTE] How can a URL with an http: protocol be a local file? The API doc for FileOutputStream(String) says: [QUOTE] Creates an output file stream to write to the file with the specified …

Member Avatar for mitch9654
0
921
Member Avatar for circusfreak

[QUOTE]calculate the min and max depth and average look up[/QUOTE] What does this mean? Can you Explain what happens that has a depth? And what a lookup is?

Member Avatar for NormR1
0
139
Member Avatar for haxin

Can you define what a cluster is? Do the points enclose a shape such that a line connecting the outer most points forms a boundary for a region?

Member Avatar for kivanc
0
297
Member Avatar for Tyrone.Wilson

This is an OS issue, nothing to do with java programming. On Windows the filetypes are associated with commands by entry in the registry. The easy user interface to add your own filetype is through Windows Explorer (98 & XP) Use menu item: Tools|Folder Options|File Types. Click New and fill …

Member Avatar for NormR1
0
145
Member Avatar for rojo821

[QUOTE]hold my right click and drag the mouase you see the box [/QUOTE] Is the "box" you see part of your program? Can you describe what you see? Can you take a ScreenPrint and save the image and post it here?

Member Avatar for stultuske
0
186
Member Avatar for sowmyacrao

[QUOTE] want to create a manifest file[/QUOTE] What program uses the manifest file? Does the program have doc that define what needs to be in the file?

Member Avatar for NormR1
0
34
Member Avatar for monaprerita

Do you get any error messages in the browser's Java console? Please copy and paste them here.

Member Avatar for NormR1
0
1K

The End.