199,114 Archived Topics
Remove Filter ![]() | |
whats wrong with my program ? [CODE]public class divisible { public static void main(String args[]) { int[] divisible; divisible = new int[] {4,9,25,144}; for (int i=0; i<divisible.length; i++) { if (divisible[i]%5== 0) System.out.println(divisible.length); } }[/CODE] I want to print the total elements in an array that are divisible by 5 … | |
Hi, I have a small project that I am working on and am trying to implement an AboutForm that is odd shaped, like the splash screen for VS2010 or Photoshop CS5 etc... I have made an image (png) in Photoshop that has a drop shadow and a transparent background but … | |
I have read dozens of blogs, forum postings amd the PHP manual on this but do not seem to get an answer. my code [CODE php/javascript] $_SESSION['sessionname']=$variable; session_write_close(); echo "<script language='javascript'>"; echo "parent.location.reload(true)"; echo "</script>"; [/CODE] works well with chrome, as I can check the existence of the session for … | |
Hi, I have created a mysql database containing menu dishes for a restaurant. The idea is to store all dishes on the database whether the dish is being sold or has been sold in the past. Each dish (database row) has a simple indicator (yes/no) to determine if the row … | |
Hello Guys, Here is the code that i have which works fine as it puts data to my database, but am not sure where or how to put it so then after the form has been completed i get an email to say that some one has completed the form … | |
Hi! I'm trying to save/load all my program's data with just one big serialization.(I'm really depending on this) Below are the codes I used to test serialization---but it seems that something is wrong with it. I'm too confused, since I learnt serialization as a 'magical genie' kind of thing that … | |
Hi, Does anyone know if there is a way in MySQL to have it return the column names qualified with the table name? For example, suppose I have the query, SELECT * FROM Items, Sales; and the tables Items and Sales both only contain columns named ID and Count. By … | |
Hi all, I'm having a lot of difficulty trying to get this program to compile. I'm pretty new to C++, but what I've come up with so far makes logical sense to me, and I don't understand what the message "Request for member 'displayBoard' in 'game', which is of non-class … | |
Hi Everyone. Can someone assist me? I'm pulling data from a DB, If the first value is empty it should check the second one and if that is also empty assisgn value. Hope it's understandable. Regards [code] if(empty($veh_img)){ $galpic="image.gif"; }elseif(empty($disk_img)){ $galpic="image.gif"; }else{ $galpic="$disk_img"; } [/code] | |
Hi This is Amol im running C#.net program. I executed the program with csc form1.cs command it got compiled correctly but when i run its exe file form1 it gives error Application failed to inialise properly 0x000007b click ok to terminate it Please give me proper solution to this error … | |
Hi guys! I just wanna ask on how to access the first character in a string? | |
i need to make a simple paint application using java where i need the function of BRUSH. i don't know much about UI. please help me. thanks. | |
hi, i was working on calculate the birthdate when user select the date,month,year by combobox. the age should display on textbox. i have wrote some code but it show the error messsage. can any one solve this please [CODE] public static int CalculateAge(DateTime birthDate) { DateTime now = DateTime.Today; int … | |
hi I'm trying to create a player class for irrlicht the main game file calls it like this [CODE=c++] CPlayer cPlayer; player = cPlayer.Create();[/CODE] the thing is that the function must return the player so the function must be scene::IAnimatedMeshSceneNode*. player header [CODE=c++]#ifndef __C_Player_H_INCLUDED__ #define __C_Player_H_INCLUDED__ #include <irrlicht.h> using namespace … | |
hi,....i wanted to develop a web application using java .... I know servlet,jsp,struts,hibernate...bit of spring and EJB could u suggest some good project idea ..... i was thinking of doing a toprated movie database....any other suggestion is welcomed or what could be the possible features .... | |
Hi Guys! I have program here which user are able to submit username and can be displayed.Currently I made 2 forms. Form2 is the submit form where the user can type in their username and press the submit button; Form1 has a label in it which displays the username. the … | |
I think I already know the answer to this, but just to be sure, is there any way to connect to a MySQL database in VB? | |
Hello This is my first post on this forum. I have found that this place seems to have lot of knowledgeable people when it comes to Python. Anyway I'm quite new to GUI programming and I'm not exactly having a huge problem but I'm more interested about how to make … | |
I can't seem to understand why I cannot run this. Please explain. Thank you in advance. [code] #07/22/2010 #Write a program that will calculate a 20% tip and a 6% #sales tax on a meal price. The user will enter the meal price #and the program will calculate tip, tax, … | |
First let me say, please don't post code back all fixed. If you see where the error is, just tell me where it is and I will look to find it. Thanks, much appreciated! [CODE] /* void processCmdLine(void) Function: parses the command line using gettok(), and constructs an argument list. … | |
Hello, I've got a page that I've created that allows me to change multiple values in a row in my database. These values are all stored in a single row. I have input boxes for every one of the columns in my row. If a box is filled in, that … | |
Hi Everyone! Is there anyway to create A program which can demonstrate the following function: A capsule machine(Similar to a candy machine),when you,say,insert a coin into it and can randomly pop out a capsule containing an item in it? How(or any possible way)is to code the probability for a particular … | |
How do you open a window on the same page? (response.redirect will go to the other page.) Thanks. [CODE] Protected Sub DropDownList1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles DropDownList1.SelectedIndexChanged Select Case DropDownList1.Text Case "First Meeting Room" Response.Redirect("http://localhost:52952/RoomSetting/FirstMeetingRoom.aspx", False) Case "Second Meeting Room" Response.Redirect("http://localhost:52952/RoomSetting/MainMenu.aspx", False) End Select End Sub … | |
I have made the treasure hunt game using 2D array. where '#' are the walls '*' is the border of the game. i want to place '@' as tresure at random postion between the spaces of 2D Array of size [20][20]. i know i have to use #include<time.h> time_t t; … | |
Hey guys, Im trying to learn python and i decided to try and make a text based tic tac toe game. I dont have the matching up yet (where the rows say there are 3 in a row they win). But I have this so far and as you can … | |
What I want to do is get my screen into a pixel array(array or rgb structs). I got a program running that loads a .bmp and does this but I want to skip the manual printscreen and loading and get it straight into an array. I searched a lot for … | |
Is this: A)[CODE]while (!isLegal(move, board))[/CODE] the same thing as: B)[CODE]while (isLegal(move,board) = !!)[/CODE] ? | |
I try to modify the below code by using the Arrays but unable to success , would someone help me please. Thanks [CODE]//Outputs the lowest, highest, and average of inputted temperatures //using an array structure #include <cstdlib> #include <iostream> #include <iomanip> using namespace std; int main() { //input variables float … | |
hi.. can anybody help me to list a few java security problems and its solution? i hope somebody will help me.. thanksss.. | |
I have made my three textbox disable in code behind [CODE]if(!ispostback) { textbox1.enabled = false; textbox2.enabled = false; textbox3.enabled = false; }[/CODE] then I have three checkboxes that corresponds with the three textboxes, chkbox1 for txtbox1, chkbox2 for txtbox2 and so on. How to do enable it using javascript? i've … | |
I finally got this exercise working and i just need someone to tell me im awesome. Or just some feedback or tips on what i can improve(probably alot:)).[QUOTE]Write a program which performs addition, subtraction, multiplication of matrices. The dimensions of both the matrices would be specified by the user (dynamic … | |
Okay. I created a program to create a character, and it uses a random number generator to initialize the Character classes strength and dexterity. Here's the character class constructor. Since the random number generator is based on time, both strength and dexterity have the same value when they're initialized. Is … | |
Well I'mm 14 years old and I'm very interested in learning some programing languages like c++ and so on . I don't know were to start at , or what to do i have no money to go buy books to learn , if any one could point me on … | |
Hello, I have done how to find out co ordinate(x and y axis) of a point on an image where a user clicks. But I need the opposite thing now. I need to mark a point on an image when a user gives suitable x axis and y axis co … | |
Ok so I am working on setting up a zencart site. We purchased a slide show from flash den and we cannot figure out how to get it to show in zencart. We have tried all of the normal stuff and it doesnt seem to work. When we create a … | |
Hello everyone, I find C not very flexible this time because I know there is an easy way to assign field values to a struct like this : [CODE]Struct mine = { field1, field2, ... };[/CODE] but in my case "mine" is contained in a bigger struct. So I have … | |
What did I do wrong? It won't does not work for my choices... [CODE]#include <iostream> using namespace std; //function prototypes void displayMonthly (double[]); void displayTotal (double[]); int main() { //declare variables and array int choice = 0; double rainfall[12] = {0.0}; //get rainfall amounts for (int x = 0; x … | |
hi guys i'm new in java and this site too i was making a small program but this mismatchexception making me angry i really appreciate if u answer my these stupid questions 1. what is token... 2. Exception in thread "main" java.util.InputMismatchException at java.util.Scanner.nextInt(Unknown Source)[/TEX][/TEX][/TEX] at java.util.Scanner.nextInt(Unknown Source) at Main.check(Main.java:63) … | |
Hi All, im trying to find a way of checking a string to see if it contains a word held in an array. If it is in the array i would like it to be replaced with cencored. the code if been working with is [code] <?php $myString = "Hello, … | |
Hello all, I think am having problem getting the add_to_list function below to work. I created it so that it accepts a pointer to a linked list, a pointer to a char array (string) and a number for occurrence of the word. [CODE] #include <stdio.h> #include <stdlib.h> #include <string.h> #include … | |
I have a dynamic drop down that allows me to select an item. That item is posted to a new page that I run a query against to build/populate my form that I'm wanting to update a column in. However the issue is after I hit my submit button it … | |
I am supposed to write a food menu program for this one summer class an i have been trying for the past 2 hours to figure it out. Directions: Write a program which allows the user to choose a beverage, sandwich and side order from a menu. After the choices … | |
Hello, I have build an html interface with a text area. I want a script that would let me search for text pasted there based on a database. how do I go about it ![]() | |
Hi folks, I am a beginner in Socket Programming. I am trying to do some simple stuff but had a basic query. I would like to implement something like wget in C top of a TCP socket (i.e., without using any HTTP libraries). Just provide a URL (Example-- $wget [url]www.foo.com/bar.pdf[/url]) … | |
Here is a problem. I have an HTML form with several fields in it. One of the fields - 'Upload file'. When I upload a file, everything works properly. But when I choose to submit the form without a file, it gives me the error message: "There was an error … | |
I have a combo box on a form (MainForm) that's bound to a column in a database table. I want this combo box to get it's list of selections from a second table (LocationsTable). Items are added or deleted from LocationsTable via a second form (frmLocations). If I have MainForm … | |
can anyone give me the source code of CAST 128 encryption algorithm written in c++ language?... I really need this for my thesis. | |
Hi, I've just created my first 2d game (c# XNA) - a car racing game. My problem is how to perform a multiplayer mode. I wanted to use MySQL server. I decided to try with a local database (SQLite) first. As i suspected it didn't work. The thing is that … | |
Hi everybody, I am trying to make the real substr function in c++ which its a member of String Class. Here what I have done: [code]void substr(char x[], int n, int n2){ char *p; p = x; for(int i=0; i<=n2; i++) *(p+i) = *(p+i+n); *(p+n2) = '\0'; // I can … |
The End.