Click here to Skip to main content
Page 1 of 212
Page Size: 10 · 25 · 50


Tag filtered by:  Java [x]
Answer 13 May 2013   license: CPOL
use servlet its fine...example given below..import java.io.DataInputStream;import java.io.IOException;import java.io.PrintWriter;import java.util.List;import javax.servlet.ServletException;import javax.servlet.http.HttpServlet;import...
Answer 13 May 2013   license: CPOL
I would suggest looking at RXTX Java Communication API. It is the one I use in my application and it works very good. I'm able to show all my usb ports.
Answer 13 May 2013   license: CPOL
You can set the attributes in jsp page. when forwarding to the action class, the data will be accessible in action class using getParameter method
Answer 13 May 2013   license: CPOL
//in java codeimport java.sql.*;import java.util.*;public class GetListData { int i=0; public List dataList(){ ArrayList list=new ArrayList(); try{ //Create Select Clause sQL and get conncetions ...
Answer 13 May 2013   license: CPOL
JButton button = new JButton(); try { Image iconImg = ImageIO.read(getClass().getResource("resources/test.bmp")); button.setIcon(new ImageIcon(iconImg)); } catch (IOException ex) { }Here, image file is assumed to be inside src/resources folder.
Question 13 May 2013   license: CPOL
M007V2CHThe classification values have the following meaning:A: ArchaeologistS: StudentV: VolunteerThe first aid level values have the following meaning:0: no first aid qualification1: level 1 first aid qualification2: level 2 first aid qualificationThe DIGS system requires the...
Question 13 May 2013   license: CPOL
dont use buffer readers or tokenizers use only a logic
Question 13 May 2013   license: CPOL
Hello everybodyi have this servlet and i passed form it to java class the value of variable" sub " but now i want display the result of sql statements in jsp what can i do.servlet: /* * To change this template, choose Tools | Templates * and open the template in the editor....
Answer 13 May 2013   license: CPOL
You cannot show video embedded except perhaps on devices that have Flash. If you can parse out the YouTube video details, you may be able to construct an ACTION_VIEW Intent that will show them on the YouTube application(for those Android devices that have the YouTube application). Also...
Answer 13 May 2013   license: CPOL
In principle there is no issue with starting threads from other threads. There's no parent child relation between Threads! There's no big advantage calling a thread inside another!The most important thing is that you might run into the point where creating more threads creates contention (due...
Question 13 May 2013   license: CPOL
Hello. I would like to ask you a question. Is it bad practice to use threads in thread? Something like: Thread bigThread=new Thread(){ public void run(){ //do something here PersonalThread pThread=new PersonalThread();...
Question 12 May 2013   license: CPOL
Hi , I have created a service , i want to read data fro it in multiple activities how i can do.anyone please provide me an example or toturialsthanksfollowing is the code of my service :public class HandleServer extends Service { private Server ser=null; public String...
Answer 12 May 2013   license: CPOL
There are many way to do that. But the best approach is using MVC/MVC2(Model-View_Controller) pattern. Lots of tutorial are present in web, read them before start.
Answer 12 May 2013   license: CPOL
You have tried to add the data stream: ABC, JFKLDJFLDKSJFLDSJFDAs you must know that special symbol "," is used as a separator in Query Commands. So, it has only added the data upto the character "," while executing the insert query on the database.Hope you got what exactly I want to...
Catalog 12 May 2013   license: Commercial
Unsurpassed Documentation Comment generation and updating for C#, Visual Basic, C++/CLI, C++, C, Java and UnrealScript code. Keep your comments readable and in sync with the code with a minimum of effort. Plus other coding utilities.
Question 11 May 2013   license: CPOL
private JPanel addToolbar() { JPanel jp1=new JPanel(); jp1.setLayout(new FlowLayout()); JButton jb7=new JButton("exit "); jb7.addActionListener(this); jb7.setForeground(new Color(00,00,255)); jp1.add(jb7);here how to set the image near to the button field this is...
Answer 11 May 2013   license: CPOL
By reading your question I think that you want to add an image on your button. You could try something like this:import javax.imageio.ImageIO; //neededimport java.io.File; public void initialize(){ //create your jframe //add you panel to it //add your...
Question 11 May 2013   license: CPOL
Hi i want to find cycles in 2 dimensional(nxm) array. i have n.m-1 filled cell in my array and i want to find cycle starting empty cell, continues in filled cells an finish in empty cell. For example we have this array;image our first cycle is [0,0],[0,3],[2,3],[2,0]second cycle is...
Answer 11 May 2013   license: CPOL
You already posted this question at http://www.codeproject.com/Messages/4562355/Finding-cycle-in-2-dimensional-array-Stepping-Ston.aspx[^]. Please post in one forum only.
Answer 11 May 2013   license: CPOL
Hi,Try this:public class Main { public static void main(String[] args) { String initialString = "line1\nline2\nline3"; System.out.println(initialString); System.out.println(); // Get each line of your initialString String[] eachString =...
Question 11 May 2013   license: CPOL
Hello everybodyI have jsp page and i want to pass parameter from this jsp page to sql statement in java classand display output of statement in anther jsp page.Thanks
Answer 10 May 2013   license: CPOL
Use this code, I have written it myself and it works:import java.awt.BorderLayout;import java.util.ArrayList;import javax.swing.BoxLayout;import javax.swing.JCheckBox;import javax.swing.JComboBox;import javax.swing.JFrame;import javax.swing.JPanel;import...
Question 10 May 2013   license: CPOL
why not return complete data from records?In a record, the data is,for example,:ABC, JFKLDJFLDKSJFLDSJFDBut when I queried the returned data is:ABCtexts after "," and including "," are not displayed.This is my RunDatabse() inside MainActivity.java, it's called...
Answer 10 May 2013   license: CPOL
The way I try to look at Breadth First Search is that you try the immediate possibilities first. Depth First you stick to one path until you hit a dead end and then try a different path. Say you are in a room with two doors that's inside another room with two door and you need to find an...
Answer 10 May 2013   license: CPOL
The first place to start is Google, which lead me straight to Wiki:http://en.wikipedia.org/wiki/Depth-first_search[^]http://en.wikipedia.org/wiki/Breadth-first_search[^]The depth first is easier than breadth first, but that is to be expected - it's a lot simpler an algorithm.
Question 10 May 2013   license: CPOL
I have looked at a few Youtube tutorials on how a breath and depth first search work on a graph but I'm still a little confused.Does anyone have a very simple explanation of the searches possibly a useful video on them or any tips on how to understand it?Thanks in advance.
Question 10 May 2013   license: CPOL
I am trying to read inputs from command line.My Input is somewhat like this :# the total size of physical memory (units are B, KB, MB, GB)512MB 2 # the following are memory allocations{abc = alloc(1KB);{y_ = alloc(128MB);x1 = alloc(128MB);y_ = alloc(32MB);for (i = 0; i...
Answer 10 May 2013   license: CPOL
Google[^] and CP Search Box[^] is your Friend :)Here are the rules: Code Project Quick Answers FAQ[^].What are the rules to posting?...4. A few simple rules when posting your question. 1. Have you searched or Googled for a solution? 1. Be specific! Don't ask "I need to...
Question 10 May 2013   license: CPOL
How to from the image segmentation qr code
Answer 10 May 2013   license: CPOL
First things first.You're so concerned about the UI in this post, but do you have working code that can track an object at all?? That's going to be FAR harder than having the user draw a box with the mouse.The problem you have is that computer vision is in its infancy. How are you...
Answer 10 May 2013   license: CPOL
The Java JMF API[^] is your Friend.
Question 10 May 2013   license: CPOL
Good day to all,this is my code check this onewhile (ir.hasNext()) { Map.Entry me = (Map.Entry) ir.next(); Log.v("remove items ", "" + Integer.parseInt(me.getKey().toString())); if (Integer.parseInt(me.getKey().toString()) == closeImage.getId() &&...
Answer 10 May 2013   license: CPOL
Because you're using the hashmap while changing the item. That does not work.How to Avoid ConcurrentModificationException when using an Iterator[^]
Question 10 May 2013   license: CPOL
Hi. I'm trying to run a recursive file search in Java to return a list of all .mp3 files on the system. Now, my background is in .NET, and I'm fairly new to both Linux and Java. My goal is to create a small crossplatform app that is capable of doing this search for me. On the account I need the...
Question 9 May 2013   license: CPOL
i want to run a video clip in java how to bring this clip in java program?after that i will do some more actions... for example.tracking of objects.finding the direction of those object etc..but first i want to know how to bring video clip , so that i could be able in the future...
Answer 9 May 2013   license: CPOL
This is the view page I commented, where I wanted the drop down list style object and what it would filter.Answers to your questions:1.Have done that.2.Atm I have the classes to create the view i posted below. I think I need to create this filter menu in order to create other classes which...
Answer 9 May 2013   license: CPOL
What you have done so far and where are you stuck ?over all1.Create an MVC 4.0 project and point to a database (does automatically up to some extend)2.Create the classes you need (Code first method)3.Generate the pages (can do automatically)If you need a menu option then have to...
Question 9 May 2013   license: CPOL
Hi! Currently I am trying to create a project where I list, edit, delete and create personal details for persons. I am at a stage where I need to create a address page.I wanted to create a drop down menu similar to a style like Html.DropDownListFor object in which I had 2 options. One option...
Question 9 May 2013   license: CPOL
I need to use some methods in JVMTI or JAVA Platform Debugger Architecture (JPDA)...But I don't know how to start, actually I think they are not supported in Java SE 7...I need to change and modify in the thread stack at run time.Can any one help me???
Answer 9 May 2013   license: CPOL
Ok. Let me rephrase it.I wanted to make a system what collect my input form command line.My input will be like this:# the total size of physical memory (units are B, KB, MB, GB)512MB 2 # the following are memory allocations{abc = alloc(1KB);{y_ = alloc(128MB);x1 =...
Question 9 May 2013   license: CPOL
My input will be from command line & it can be any variable in input loop...I have input like this :# the total size of physical memory (units are B, KB, MB, GB)512MB 2 # the following are memory allocations{abc = alloc(1KB);{y_ = alloc(128MB);x1 = alloc(128MB);y_ =...
Answer 8 May 2013   license: CPOL
Hi Kapilk,Just use an array. You read the number of of columns from the combobox and then create an array of JCheckBox:int numberCheckBox = ...JCheckBox[] checkBoxList = new JCheckBox[numberCheckBox];for(int i = 0; i
Question 8 May 2013   license: CPOL
how can i create jcheckboxes dynamically;i am getting table name in a comboBox and i want to add as many checkboxes as the number of columns the selected table have.pls help me out;
Answer 8 May 2013   license: CPOL
I've solved it using onclickevent, and getting selected item from there
Answer 8 May 2013   license: CPOL
If you want to close your JFrame, you just need to call: this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); //your main class must extend JFrame //or use this otherwise yourFrame.setDefaultCloseOperation(JFram.EXIT_ON_CLOSE);This ensures that when you...
Catalog 7 May 2013   license: Commercial
The Java Developer Program is a package that enables you to become a competent entry level Java Developer. You get access to 270 hours of content, 400+ Lab Exercise
Answer 7 May 2013   license: CPOL
Here is the [LINK] to understand how to load large bitmap and also refer to the code available to download on this page.

Page 1 of 212
1 2 3 4 5 6 7 8 9 10


Advertise | Privacy | Mobile
Web03 | 2.6.130513.1 | Last Updated 14 May 2013
Copyright © CodeProject, 1999-2013
All Rights Reserved. Terms of Use
Layout: fixed | fluid