199,114 Archived Topics
Remove Filter ![]() | |
:cool: hi Friends,.,. !! i want to know a perfect time consumption for a given particular program.. [B][COLOR="red"]IN MILLISECONDs[/COLOR][/B] I know the way of using following method: [CODE=c] start=clock(); /*... ... my programming logic . . . ... */ end=clock(); difference=(end-start);[/CODE] But it gives time in seconds , which is … | |
Hi all, I am using getBytes() method in Java to encode the String, When I encode the String some string values does not Encode.. The Code is String psString ="ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö"; psString = new String(psString.getBytes("UTF-8")); I am Using Netbeans tool for Java. In Windows XP OS , it converts in to … | |
hi, In this example: [CODE]public void init() throws ServletException { bookDB = (BookDBAO) getServletContext() .getAttribute("bookDB"); if (bookDB == null) { throw new UnavailableException("Couldn't get database."); } }[/CODE] As it is not instantiating the BookDBAO instance and the connection with entity manager is done in the constructor: [CODE] public class BookDBAO … | |
Write a program that displays all the prime numbers between 50 and 100. Below is my code: [CODE]Write a program that displays all the prime numbers between 50 and 100. please correct my mistake, thank you. #include <stdafx.h> #include "genlib.h" #include "simpio.h" #include "math.h" int _tmain(int argc, _TCHAR* argv[]) { … | |
Hi, I have created table in database mysql and I created register form and I wrote insert code ,when we run the php file there is no but given data is not inserted in database....I need help,I am new to php.... This is my code i have used,........ <?php if(isset($_POST['submit'])){ … | |
[ATTACH=LEFT]16359[/ATTACH]When PopCap Games released a disco-themed version of its [URL="http://www.popcap.com/games/pvz"]Plants vs. Zombies[/URL] game this July, it didn't expect any controversy. After all, what's less offensive than giant blossoms battling the undead? But PopCap's decision to include a zombie Michael Jackson led to[URL="http://multiplayerblog.mtv.com/2010/07/27/michael-jackson-estate-forces-plants-vs-zombies-update/"] quick action on the part of the Jackson … | |
this is my table structure [CODE]CREATE TABLE IF NOT EXISTS `test` ( `id` int(11) DEFAULT NULL, `disable` timestamp NULL DEFAULT NULL, UNIQUE KEY `id` (`id`,`disable`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;[/CODE] Assume values as [CODE]INSERT INTO `test` (`id`, `disable`) VALUES (1, NULL), (2, '2010-07-27 15:52:20'), (3, '2010-08-03 00:00:00'), (5, '2010-07-28 15:53:39'), … | |
hi all, i had a page in which list of images can be seen by selecting some date. so now in that table i am having a dropdown of users. so if i select a user and click submit that username, imagename,size,type should be stored in database,but i cant store … | |
using System; using System.Collections; using System.Configuration; using System.Data; using System.Linq; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.HtmlControls; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Xml.Linq; using System.Data.SqlClient; public partial class userreg : System.Web.UI.Page { SqlConnection con; protected void Page_Load(object sender, EventArgs e) { } protected void ImageButton1_Click(object sender, ImageClickEventArgs e) { … | |
Hi I have a question with regards to storing and retrieving a players location in a game. At the moment I'm working on a text based dungeon game, and one of the things I am having trouble implementing is, a way to move between rooms in the game world (I.E. … | |
gud day...i'm just a new member of this sites,is there somebody may help me about turbo c,turbo pascal and fox pro code,i just need a sample basic codes.i've been searching on the net and those info. was so broad and made me so confused..our instructor want us to search and … | |
I have an Update query to update a MySQL database. Everything seems to work fine except one form field..."bulbDesc". When I enter data into this field, which is longText type in MySQL, it disappears. Meaning when I go back to my view page, the bulbDesc in that particular record is … | |
Write a program that displays the table of Fahrenheit - Celsius temperatures. Below is my code, the problem with it is that the celsius column is all zeros,please correct my mistake, thank you: [CODE]#include "stdafx.h" #include "genlib.h" #include "simpio.h" #include "math.h" int _tmain(int argc, _TCHAR* argv[]) { int i; double … | |
hi all, i have a code that add dynamic row and it has an option that it allow to delete rows by checking checkboxes. can anyone help me to check all checkoboxes at here is my code [CODE]<HTML> <HEAD> <TITLE> Add/Remove dynamic rows in HTML table </TITLE> <SCRIPT language="javascript"> function … | |
[CODE]#include <iostream> using namespace std; int main() { int i,j; float a[10][10]; for (i=0; i<10; i++) { for (j=0; j<10; j++) { a[i][j]=0.2; a[i][j]=a[i][j]-0.2; cout<<a[i][j]<<"\n"; } } } [/CODE] //// why is the output not exactly 0.00 ??? how do i make it output 0.00 | |
[ICODE]class classA: #saved as classA.py def __init__(self): print "class A" printB() def printB(): print "B"[/ICODE] [ICODE]>>> classA() class A Traceback (most recent call last): File "<pyshell#0>", line 1, in <module> classA() File "C:\Documents and Settings\Owner\Desktop\timetable\classA.py", line 5, in __init__ printB() NameError: global name 'printB' is not defined[/ICODE] Using the class … | |
I know, is a very basic question, but I am in the process of re-learning sql stored procedures, and this is what happended: I was practicing with some simple delete / insert routines, when encountered with this: if I ONLY insert records: 1. dog 2. cat 3. t-rex 4. llama … | |
Hey does anyone know how can we detect virus using c++. | |
Can anybody pls help.. I need the script to upload image in ASP... Thanks in advance... | |
I am trying to get a Console using System.console() method, but it returns null. Please let me know how to get a Console object? Is their other criteria need to be satisfied? | |
Hi there, I couldn't find a solution to this small problem so posting it here. I have some hardcoded values I want to send back to the browser. When I have this code: [code=php] ... $cr1 = '{"date_added":"8/3","type":"1","contact":"John Smith"}'; $cr2 = '{"date_added":"8/7","type":"2","contact":"Jane Smith"}'; $company_reqs[0] = json_decode($cr1,1); $company_reqs[1] = json_decode($cr2,1); $company_data['reqs'] … | |
I have to write this applet for my CIT 130 class. I understand that you can not give solutions nor do I want you to do my homework for me I just need some pointers. The questions ask to "Write an applet that draws a house with it's door and … | |
I have an assignment in class I'm and almost done but I need help with one part. Within each subject in the output file, list the students in alphabetic order, sorted by last name. Do not change the given case (upper/lower case) of the names that were read from the … | |
Hey guys, iam assigned a program that has to read in 3 values (sides of triangles) at a time and find the area. The values have to be read from a file, they are in a loop as there can be as many sets of triangles as the user wishes, … | |
Hey guys, I've created a java applet which calculates PPI. my problem occurs when I add it to a webpage on dreamweaver. I get the following error message: [QUOTE] load: class calculator.java not found. java.lang.ClassNotFoundException: calculator.java at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source) at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown … | |
Nevermind, simple solution | |
I posted a thread a bit earlier about a simple error, but this is more of my main issue. I have a struct: [CODE=C++] struct Inventory { string ItemName; int ItemQty; float ItemPrice; }; [/CODE] with the intention of creating an array for storing an inventory array. I can't seem … | |
Can somebody on a beginners level explain the code below [CODE] int i, j; for(i=2; i<16; i++) { for(j=2; j<=(i/j); j++) //confusion 1 if(!(i%j)) break ; if(j>(i/j)) cout<<i<<" / "<<j<<endl;//confusion 2 } [/CODE] | |
So I have this two dimensional array in my class, and I'm trying to create an accessor group for it. But the compiler doesn't like what I'm trying to do at all. [CODE] private int[,] _resource = new int[5, 2]; public int Resource[int idx1, int idx2] { get { return … | |
Hello, We have make a program to log out a rs232 comport,all the data that we read out is in asci. But now on newer version there is also a keep in live string on the rs232 port with that string we keep open the comport to send and receive … | |
After searching through this forum and other forums relating to C++ and Dynamic Memory; I would like to know the indepth reason on why do you have to declare a dynamic memory allocation in either a Class or in a function for the program to compile? e.g. [code=c++] //place a … | |
Textbooks are among the top expenses for college students. Today Barnes and Noble launched its app to eliminate at least some of the production costs for textbooks. The company released NOOKstudy, a Web-based e-Textbook application that can bring students a 50 percent savings, according to an announcement today. [ATTACH]16370[/ATTACH]“We’re thrilled … | |
Dear Friends, Please help me with this issue. the design of my database isnt well normalized, but due to the ammount of work done based on this queries i found it more difficult to have to change the whole design . Instead im trying just to solve it. i have … | |
Hi, I just struggeled all day how can I build JavaFX Application made with visual composer plugin in Nebeans. Every other application worked but this doesn't. When I build it says can't find [I]javac[/I]. Of course, javac .exe is not located in the JRE... [CODE] Cannot run program "C:\Program Files\Java\jre6\bin\javac.exe": … | |
How do I compare what is in one array with what is in another array? | |
hi, I use: [code=java] fOut = thecontext.openFileOutput(filename, Context.MODE_PRIVATE); [/code] Does the private mean that unless you have the phone and are the user of the phone or otherwise got your hand on it, that no program can read the file I'm writing? I.e no installed program could request any permission … | |
Hi. I am new to C# and a little stuck on arguments to pass to an external function. The intelisense tells me the function has these parameters [code]void LPP.XRS_Search(int x, int y, int w, int z, int cl, int vr, int sp, int[] PointResult)[/code] here is my call [code] int[] … | |
Hi, select row_number() over(order by b.inv_no) as sl_no,b.fyear_code,b.inv_no,b.inv_date,b.service_nature,b.inv_total,c.bal_amount,b.client_code,b.amt_received from fn_receipt a, trn_invoice_history b, mst_expenditureinvoice c where a.client_id=b.client_code and a.client_name=b.client_name and a.location=b.client_location and a.receiptno=35 and b.fully_recived not in ('Y') and b.amt_balance>0 and (c.fyear_code=b.fyear_code and b.inv_no=c.inv_no) union select row_number() over(order by b.inv_no) as sl_no,b.fyear_code,b.inv_no,b.inv_date,b.service_nature,b.inv_total,c.bal_amount,b.client_code,b.amt_received from fn_receipt a, trn_invoice_history b, mst_invoice c where … | |
Why is it that when I call recordCount on a rescordset it returns 1 even when I know that there is two different records in it and able to access those two records in the set. | |
Now, knowing I'm fairly new on this whole PHP, MySQL, and HTML project. I'm working as an intern and my boss has run out of things for me to do so I'm creating a data driven website for him. I'm having a hard time with getting to work right. Here … | |
this snippet is to create random passwords with a chosen length and a specified number of numbers. Uses both lower case and capital letters, which are chosen at random. And example is: wep5Q268LtTe. [B][U]How to use.[/U][/B] Using this is very easy just add to the appropriate page and call the … | |
This is a User Defined Function to perform simple encryption on an input string. This is performed by transposing the ASCII value of each character in the string by the increment value (@increment in the parameter list) Pass the function the string you wish encrypted and the increment value, which … | |
Solving the greatest common divisor using C++ and the Euclid method Below is my code: #include "stdafx.h" #include "genlib.h" #include "simpio.h" #include "math.h" int _tmain(int argc, _TCHAR* argv[]) { int num1,num2,rem; printf("Enter 1st number: "); num1=GetInteger(); printf("Enter 2nd number: "); num2=GetInteger(); rem=num1%num2; ;if(rem==0) { printf("The GCD of %d and %d … | |
I just used: ant ant deploy and it gave me following error: [code=text] deploy: [echo] localhost [echo] 8080 [echo] order [echo] C:\glassfishv3\glassfish\docs\javaee-tutorial\examples\bp-project\ma in.xml/../../../../../../bin/asadmin.bat [echo] order [echo] SQL92 [exec] Deprecated syntax, instead use: [exec] asadmin --port 4848 --host localhost deploy [options] ... [exec] com.sun.enterprise.admin.cli.CommandException: remote failure: Excep tion while loading the … | |
Hi, I've been trying to make a poker game, i got the basic things running like giving the cards to the player and dealer, but i am having trouble coming up with a way to compare the 2 hands... I'm new to python, i tried different ways and didn't really … | |
Hi all, I have a big problem. I am very new to php and sql and I need to create a login web page page for access to a database I have created in mySQL. I have located a script online here: [url]http://php.about.com/od/finishedphp1/ss/php_login_code.htm[/url] that basically explains the entire process. My … | |
Maybe someone can figure this out because I sure have been having problems with it. I am looking to have a javascript that can be included a page that can highlight or set a border for a the div, p, span, or img DOM element when clicked on. Now this … | |
Hi all, 3 tables : one events table (each event can have differents types) one types table (each type can have differents events) and one liaison table (link between events and types tables) I have some problems when I show screen. [code=php] <select name="type[]" size="10" multiple="multiple"> <?php $req_type = "SELECT … | |
Hi, I am outputting a query into a table. I am listing titles of workshops, and dates and times. If there is more than one date/time for a workshop, I add a separate row for each date/time. I would like to have all the rows for each workshop be the … | |
Hello, I could use a spot of help today. I am very new to python (n00b) and I have a rather specific Issue I am trying to resolve. This problem can be solved using ArcGIS (for those who know it) I simply desire to know more about python so I … |
The End.