User control click even on main form
I have a user control that I created and I need to be able to click on the button on the user control and have something happen on the main form. Now, I did this several years ago, but I don't remember...
View ArticledrawImage in graphics only for INT numbers?
Is there any way that I can draw with doubles number in the paintComponent method for JPanel? I really need it to draw with double numbers
View ArticleDetect USB barcode reader scan without focus
Hi All, I have a rather unique set of requirements. We use a vendor-provided web app for a materials handling process. As user scans many parts, the web app quickly accepts the part# and displays...
View ArticleSomethings wrong with my drawImage
public void paintComponent(Graphics g){ g = f.getGraphics(); Graphics2D g1 = (Graphics2D)g; g.drawImage(bg,0,0,null); while(isRunning){ try{ for(int i = 0; i < living.size(); i++){ Spawn s =...
View ArticleThrowing Exceptions Back to Main Method
Hello everyone I have a question I cant seem to find an answer for. I am reading a file and my assignment requires I handle a few different exceptions. Now it says that error messages must only print...
View Articlefor loop help
I just started learning loops in java and given this exercise: Suppose that the tuition for a university is $40,000 this year and tuition increases 3% every year. Write a program that uses a for loop...
View ArticleSend message to multiple clients
I want to send same message from server to multiple clients. How I can do it? import java.io.*; import java.net.*; public class ServerChat implements Runnable { static ServerSocket server; static...
View ArticleAbout Listview Control
Hi!, Please tell me how can I add/enter text at run time in listview control (as sub items). i.e. I have 4 columns in Listview Control No. Item Qty Rate when I select P.O. 1 from combo box then it...
View ArticleArray subscript won't increment in switch statement properly
You will notice that I have different statements in each case in my switch statement. This is because I have been trying different methods to get my array to increment properly. I essentially want to...
View ArticleUpdates Item in ListView
Hello Guys Help Me To Count The Item in Listview and Update it. Scenario.. Customer Buy 3 Milk and 2 Nescafe then the Cashier Punch it Item-----------------Qty Milk-------------------2...
View ArticleCraps game
I have to make craps program in which the program asks the user how many iterations/time he/she wants to play this game, and what is the maximum amount of much money he/she wants to bet each time. For...
View Articlechess code
am having a problem with the following code for chess ,it doesnt place the pieces or darts on the board to be visible,so please help me what is the problem with it? /* * To change this template, choose...
View ArticleHow to make this happen !
I want to create a program for simple Blackjack game. Not with the aces and kings and queens but just with numbers from 1 to 11. The player will get 2 cards first, and the dealer will get 2 cards too...
View ArticleHow can I print a file in the reverse order?
I have a text file and i need to print the lines in the reverse order THE QUESTION: If the file has more than five lines, it will print ONLY the first five lines in the reverse order. If the file has...
View ArticleHow to compare strings
My question is.. How can I compare two strings? It's for the game: FLAMES For example: txt1.Text = "Sophia" txt2.Text = "Patricia" I want to count how many the same letters do these two strings have....
View ArticleHow to refresh my combobox
Hi. This is my first post to this forum. I've read the rules, written before asking the question in multicolor fashion. some were not picked by my mind but if any mistake then please guide me. I've a...
View Articleerror on my for loop, type mismatch dont know how to array data fields
what im trying to get in this code is that, first i search if theres a same reocrd existing on my database,on a field on my table, field name Status, i conditioned it if the status is approved this...
View Article3D tutorials for java
hello me and a friend have decided to try to make a little 3D game but neither of us have any idea on 3D with java. my question is do you know any good 3D tutorials for java that don't require a...
View ArticleWhen opening a form via button it shows a new empty form
Hi, im working on a launcher for my game, and when i run it i hit the options button, i opens a form, but it opens the new empty form. Now my question is why i am getting a completely empty form? This...
View Article(OneToMany relation)how to save the date through Mapping in java
hey,, i am mapped(onetomany relation) the java file ,, i have done map a file and also generate the table in sql,, but i cant save a value in mapped file,,,,,, i doing map a file class and section.. if...
View Article