199,114 Archived Topics
Remove Filter ![]() | |
I make a program that reads a file and then it stores the information in two char.The problem is related to the char Elements and symbol. What is causing errors in my program? Thanks in advance. [CODE]#include "stdafx.h" #include <iostream> #include <fstream> char* Elements;//The problem char * symbol; using namespace … | |
I hope this hasn't been discussed before. I searched but couldn't find a thread for this. I have an input (type="text") with some default text telling the user to enter something in the box. The input tag includes an onmousedown event which runs javascript function to clear the default text … | |
Hi, I am a beginner so bear with me. I have an assignment in which I have to create an array with numbers and then have a loop with condition to check in which order the user has inputed the numbers. Asc=1, desc=-1, other=0. This loop isn't working, i know … | |
I have a large number of files that begin with numbers (e.g., 10admin_boundary_x) and would like to rename the files so that they do not begin with a digit (e.g., admin_boundary_x). I am working with shapefiles (.shp, .shx, .dbf, etc) and thought a python script could save me some time. … | |
Hi. I'm making a form with some fields. Once the form is submitted it updates the page with a new div containing the data entered without refreshing. Im using jquery form plugin. What I'd like to achieve is the new div(.record) to .slideDown. I guess I need to somehow specify … | |
[CODE]#include <iostream> #include <fstream> #include <string> #include <iomanip> using namespace std; string constestantName(istream &); //Calls the the input file from main() by refrencea and returns the name of the contestant void getJudgeData(istream &, string, int); //gets the scores from starsearch.dat and stores them in five veriables void CalcScore(ostream &, string, … | |
Can anyone see anything wrong with this statement? [CODE] CREATE OR REPLACE VIEW V_DEPT_AMOUNT AS SELECT DEPTNO AS DNO, DNAME AS DNAME, MAX(AMOUNT) AS MAX_AMOUNT, AVG(AMOUNT) AS AVG_AMOUNT, MIN(AMOUNT) AS MIN_AMOUNT, SUM(AMOUNT) AS TOTAL_AMOUNT FROM DEPT D, EMP E, PURCHASE P WHERE D.DEPTNO = E.DEPTNO GROUP BY DNAME, DEPTNO; [/CODE] … ![]() | |
[QUOTE=;][/QUOTE] Hi, every one. Through the help of talented programmers and contributors, I have been able to get some were with the program design and coding process. Thanks to you all. I want help in resolving this problem, Pls. I created a database with the following information, but I wanted … | |
I'm trying to compile this simple dot program with C++ that uses OpenGL. I made a struct GLintPoint to hold just points x and y. It seems I didn't delcare the struct according to the errors. [CODE]#include <GL/glut.h> #include <stdlib.h> #include <time.h> struct GLPoint { GLint x; GLint y; }; … | |
i have [CODE]program p1032; const n=10; num=4; var i:integer; a:array[1..n] of 1..n; procedure tipareste; var i:integer; begin for i:=1 to num do write(a[i],' '); writeln; end; procedure permuta(k:integer); var i,x:integer; begin if k=1 then tipareste else begin for i:=1 to k do begin x:=a[i];a[i]:=a[k];a[k]:=x; permuta(k-1); x:=a[i];a[i]:=a[k];a[k]:=x; end; end; end; begin … | |
Can someone help me convert my .cs file to aspx.cs I thought I could just put my same cs code into this file that would open a webpage but apparently things are different. I need this because I have a login file that has three options for the user, the … | |
[CODE]#include <iostream> #include <string> using namespace std; //char inventoryRequest = 'i'; //Function Definitions. void exitGame(); int playGame(); int main() { //Menu Text. cout<< "\t******Menu******\n\n"; cout<< "Please choose one of the following:\n"; cout<< "1 -Play Game.\n"; cout<< "2 -Exit.\n"; int choice; cout<< "Choice: "; cin>> choice; string name; switch (choice) { … | |
Here's what I want: [CODE]$practice_name = preg_replace("/\([^\)]+\)/","",$practice_name); echo($practice_name); [/CODE] But that does not work when I reference the variable then. This however does work. [CODE]echo(preg_replace("/\([^\)]+\)/","",$practice_name));[/CODE] But I do not want to update my code every time I reference $practice_name, I only want to update where the variable gets assigned. | |
I know a FOR loop is for definite loops when you know the starting value and ending value. It use step value (number use to alter a loop control variable on each past of the loop) in which the control value changes after the body executes. A for statement is … | |
Hi.. this is not a "which is better" thread, although if you happen to have a reason for thinking so, please share your thoughts. First I just want to say that I do not want to have any flame wars or arguments or anything like that. Please keep emotional arguments … | |
I have searched high and low and cannot find anything that I understand on how to pass data from one form to another in c#. I am completely new to this language and I felt like I was really grasping it up until now. The situation: I have a project … | |
hello people. how are you all doing? my problem is i have been programming in c++ for almost a year now but i have always used windows with microsoft visual studio and dev c++ but now i discovered that programming in ubuntu is much more fun couz it is way … | |
1)Write Python code that asks the user for two angles of a triangle. Then, first determine if the triangle can exist (make sure that the third angle can be found such that the sum of the three angles is 180°, with all angles both given and computed conforming to the … | |
I want You to ask for a help. how to adapt this VB.NET code to Visual Basic 6 ? [CODE] Imports System.Collections.Generic Imports System.IO Imports System.Net Namespace blogtest Class Program Private Shared Sub Main(args As String()) Dim http As New simplehttp() ‘testing on ipcheckit.com so we can make sure we’re … | |
Hi need help with regards to deducting from customers purchases. The fields look like this: tblStocks: Name Type Qty Pencil 2 15 Pen G-Tech 5 When the customer would purchase 2 pencils, the datagrid field qty would be 13..Does anyone here know how to do this? | |
Hello everyone. I am having a problem with my program; it is supposed to read values from an input text file, put the data into a structure, then output the data from the structure into a binary file. The first 2 parts work fine, but I keep ending up with … | |
heres my C code this was easy: -Chris g [CODE=c]#include <stdlib.h> #include <stdio.h> extern int numodd( int array[], int size ) ; int main( int argc, char * argv[] ) { int numarray[] = { 2, 3, 1025, 3024, 4057, -3, -1025, -3578 } ; int size = sizeof(numarray) / … | |
Hi everyone :) I am working on a small error message, but i can not seem to get it to work correctly. Basically, what I am trying to do, is check the account balance field from a mysql database against a variable of $smsnum smsnum is automatically populated based on … ![]() | |
write a java program that prompts the user to input and integer and then ouputs both the individual digits of the number and the sum of the digits. This is what I have but it is not working when I input a negative number. Why? Need help! import java.util.*; public … | |
Guys, I have those records. how to i removed the first 10 records and the last 2 records(-U)in string. P300-1110-C731-U P300-1110-INCREDIBLE-U P300-1710-DEVOUR-U P300-1710-DROID2-U P300-4410-THUNDRBLT4G-U P333-4110-8530-U Here is the correct Result: C731 INCREDIBLE DEVOUR DROID2 THUNDRBLT4G 8530 Thanks in Advance. Jonel | |
Hello everyone I am a college student learning c++ and I am not understanding why you put a "For loop" inside of another one. What advantage does it have and what can you use it for. For example: [CODE]for (int i = 0; i < 5; i++){ for (int g … | |
Hi. I have to write a program that solves the Knight's Tour in C++. The Knight's tour is where the Knight Chess piece has to move to every space on the chessboard only once. I am new to programming and I'm having trouble figuring out why my program has stopped … | |
Hey I'm Dean I'm taking my BSc from distant learning so sometimes it takes forever to get the teachers or other students to help me on stuff I'm stuck on anyways. I'm given a task to show a quiz with a little clock running and to end the quiz and … | |
[CODE]#include<stdio.h> #include<conio.h> int n,a[10]; void display(); void insert(int); int del(); int main() { int i,item=0,j; n=1; printf("enter the numbers:"); for(i=1;i<6;i++) scanf("%d",&a[i]); for(j=1;j<5;j++) { insert(a[j+1]); } } while(n>1) { item=del(); a[n+1]=item; } display(a); getch(); } void display() { int i; for(i=1;i<6;i++) { printf("%d ",a[i]); } } void insert(int item1) { int … | |
hi , I have database 'center' with huge data and wanted to create a dummy 'test' database for 'center' db with 1000 random data for testing purpose. I generated script to copy the db but the resulting 'test' db was tables without data. i need 1000 samples for all the … | |
Hello there! I was tired of having to edit my hosts manually, so I just started a small app that will open a nice user interface to it for me. Most of the code is done. It opens the hosts, edits, saves, has cut, copy, paste, undo and redo functions. … | |
I'm using the Win32 API to create a game, and I want to give the player as big of a field of view as possible. The problem is, with the game engine I've developed (from Michael Morrison's [I]Beginning Game Programming[/I]), I can minimize and close the program, but I can't … | |
my problem is highly conceptual problem. when i write: node *new1=malloc(sizeof(node)); it works properly. but when i write : node *new1=malloc(sizeof(node*)); it starts giving errors. // node is the structure having a integer and pointer to itself. | |
i want to write an algo about stack example.. that is, ""When a person wear bangles the last bangle worn is the first one to be removed and the first bangle would be the last to be removed. This follows last in first out (LIFO) principle of stack."" how to … | |
Hi, To explain once my app is added to windows path you can simply call it from CMD and you know how when you run a console it opens up a default folder and you can navigate to a new on by using cd .. and cd path command. I … | |
Hi All, I am new to C++, I am tring to generate the random number from 0-99, and save it to a matrix array with the size of 10x10. Below is my code, the resule comes out funny. Can you help to see what goes wrong? [CODE]#include<stdio.h> //Header file #include<stdlib.h> … | |
Hey guys im trying to write a code to give me Arthimetic mean and standard deviation for 4 Integer values... i don't know what im doing wrong it's not letting me compile any ideas?? [CODE] #include <iomanip> #include <iostream> #include <cmath> using namespace std; int main(void) { int X1; int … | |
Alright so I have to Save and Load an array, and I am unfortunately running into issues at saving, where it keeps giving me the error[QUOTE]Exception in thread "main" java.lang.NullPointerException at java.io.FileOutputStream.<init>(FileOutputStream.java:186) at java.io.FileOutputStream.<init>(FileOutputStream.java:84) at SocialEventList.saveAppointmentData(SocialEventList.java:41) at Test.main(Test.java:120)[/QUOTE] [CODE]import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.PrintStream; public class SocialEventList { private SocialEvent[] … | |
hello there it my first thread on this forum. well i need some help. See i am thinking abt making my own video player not for any project kinda thing but for my wish and knowledge. I am good in C and java, with help of C i learnt c++ … | |
I m running the Sql job as background thread and at the same time showing data from sysjobhistory table in gridview. While debugging the code its shows the data in old and new rows affected from table in gridview but when i put the application in debug or release mode … | |
I need some idea how to correct this program. Though I think I understand the concept, my implementation is wrong. My program only prints the orignal string and does nothing with it. [CODE] public class ArrayStack<E> implements Stack<E> { protected int capacity; protected static final int CAPACITY = 1000; protected … | |
Hello again I'm dealing with a problem in VB6 I have the swedish version in the national enverionment as default and the [U]LabelDatum.Caption = StrConv(Format$(MyDate, "dddd dd mmmm yyyy"), vbProperCase)[/U] is saying SÖNDAG in the first form but I will change that with some code in the form2 that the … | |
Hi i am currently creating a login screen for my project.The logical error with this code is that it does not display the message "invalid password" although i have written a code for it.Can anyone please tell me whats wrong with this code.Thanks in advance [CODE]using System; using System.Collections.Generic; using … | |
[CODE]<? ob_start(); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Guitar Wars - Add Your High Score</title> <link rel="stylesheet" type="text/css" href="style.css" /> </head> <body> <h2>Guitar Wars - Add Your High Score</h2> <?php require_once('appvars.php'); require_once('connectvars.php'); if (isset($_POST['submit'])) { // Grab … | |
Hi all, I did some basic method overloading program, when I run the bellow program i got output as int long but expected is short long.. can Any one explain me My code is : [CODE]public class MyClass { public static void disp(Long n) { System.out.println("Long "); } public static … | |
Hi, Does anyone know a function that prints out binary tree in this form example : ................15 .........12.............17 .......10 14.........16 18 ? my Node class : [CODE] class Node { double Node_Data; Node Left_Child; Node Right_Child; Node Parent; }[/CODE] | |
I am trying to get the program to print how many of each letter of the alphabet is in the bible but it is throwing and error. I am just using a small part of the bible until I get it to run properly. Please help. import java.io.File; import java.io.FileNotFoundException; … | |
Hello, I am using Delphi2010 and TOracleDataSet to access tables in Oracle. My question is how do I insert rows to multiple tables? I was told to use the AppendRecord method. Here is an example: [B]Example of value statements (this has been shortened obviously):[/B] Suffix := trim(edSuffx.text); Salutn := trim(edDear.text); … | |
hi, i'm trying to make a simple program to calculate the area and perimeter of a circle, but there's a little problem, whenever i enter a floating point number as the radius, like say 2.5 it calculates as if i entered only 2(without the .5) ( i hope that makes … | |
I have to learn how to deal with socket programming because of my job(I don't have any experience about it) My company ask me to learn ACE because I have to maintain our ex and new products After I google the information from the internet, most of the users say … |
The End.