132,726 Archived Topics

Remove Filter
Member Avatar for
Member Avatar for atrix415

hi, I seem to gotten my code run. But what I want is to display everything into a dialog box all at once. So when I type 3 it would display all the factorials starting from three...to 15 and display them according to number / Factorials. 5 to 15 all …

Software Development display java java-swing
Member Avatar for masijade
0
143
Member Avatar for wenny86

this is the one I tried.. but it just can store digit up to 9... I need to store large number. can anyone help me?? [code]#include <iostream> #include <assert.h> #include <cctype> #include <cstdlib> using namespace std; #if !defined STACK_H #define STACK_H const int maxStack = 100; class IStack { friend …

Software Development c++
Member Avatar for siddhant3s
0
3K
Member Avatar for Agentbob

I'm trying to convert decimal to binary and I'm having a lot of trouble (new to python). I was wondering why that won't work. Thanks. EDIT: Argh, I'm so sorry but I got it fixed. It turns out that the assigned variables are on the wrong side.

Software Development python
Member Avatar for vegaseat
0
173
Member Avatar for cwarn23

I have found a program and tried using 'DEV C++' but it only reported an error report. I later then discovered that is was because 'DEV C++' used C++ when the code was designed for just plane C. I have searched the web and this forum but only found two …

Software Development c c# c++
Member Avatar for Kocmotex
0
514
Member Avatar for twooften

I do not want to misguide anyone responding, I am a newbie to the C++ arena. I am just doing little starter programs to figure things out, but for the life of me I don't get the whole hInstance thing. The objective I have is to learn C++, write a …

Software Development c++ objective-c windows-server
Member Avatar for twooften
0
1K
Member Avatar for jobs

I am looking at this recipe: [url]http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/440509[/url] When I tried to do it, doesn't work. why? [CODE]>>> from sets import Set >>> new_list = [2,34,5,5,6,6,7,2] >>> print new_list [2, 34, 5, 5, 6, 6, 7, 2] >>> new_list = Set(new_list).elems Traceback (most recent call last): File "<interactive input>", line 1, …

Software Development python
Member Avatar for vegaseat
0
616
Member Avatar for woozyking

My problem was over here: [url]http://www.daniweb.com/forums/thread93806.html[/url] After many advices, helps, I could eventually solve this problem myself, happy~~:D All I did was to write a replacement function for strcmp() and then use a bubble sort function to sort input strings in lexicographical order. Much simpler than nasty nested loops :P …

Software Development algorithm c
Member Avatar for Ptolemy
0
338
Member Avatar for Church

thought i'd make a program for fun.. although to be safe im cutting it up into many forms to save room. Anyway doing this means im going to have to get alot of the variables from the forms back to the original page, and then back to a different form …

Software Development vb.net visual-basic
Member Avatar for Church
0
116
Member Avatar for wenny86
Member Avatar for addicted

hey, I am a beginner in c++ and i think i have learnt a little about how the program functions... I have been able to write programs that can run only in the DOS mode and i cant even write a windows application but i now understand the program a …

Software Development c++
Member Avatar for Ptolemy
0
93
Member Avatar for theteamdrunk

I need help with this problem. I have written the code. The function main() stores the message in an array. What I need to figure out is how to have the function restaurant accept the message as an argument(which is named menu) and display the message using pointer notation *(menu+i) …

Software Development c
Member Avatar for Aia
0
103
Member Avatar for death_oclock

So I have this code (the unnecessary parts omitted): [CODE=c++] #include <stdio.h> #include "scene.h" int main() { while(1); return 0; } [/CODE] And another file in the project called "scene.h". When I compile, I get these errors: [CODE] new types may not be defined in a return type extraneous 'int' …

Software Development c++
Member Avatar for death_oclock
0
252
Member Avatar for HLA91

Hi all I am using a tutorial on youtube[URL]http://www.youtube.com/watch?v=sIy3oOguh_0&mode=related&search=[/URL] and it is going well apart from I can't compile the latest program, a calcualtor my compiler (devC/C++) keeps highlighting the endl; near the end of the code, i have placed a comment above it. I have checked the video many …

Software Development c++ video
Member Avatar for HLA91
0
123
Member Avatar for denniskhor

Write a program that prompts the user to input a number of positive integer values which is terminated by an appropriate sentinel value (you can choose -1 as the sentinel value) and then prints out the largest value, the smallest value, the average value and the number of prime numbers …

Software Development java
Member Avatar for Chaster
0
118
Member Avatar for Max_Payne

How can i make a string that will allow me to Use Spaces between the words ??? This code only allows me to post words without spaces. [code] cout << " Enter the Name of Employee # " << i+1 << ": "; cin >> N; myClass[i].setName( N ); [/code]

Software Development c++
Member Avatar for Max_Payne
0
145
Member Avatar for winky

I am currently studying the impact of microarchitectural techniques. I have been looking at code and how to stall it correctly, as well as how to make it more efficient. I have been doing this through several different methods and then measuring the cycles per iteration. I was wondering if …

Software Development assembly
0
79
Member Avatar for woozyking

Hi, I want to write a function to perform lexicographical sorting using a simple bubble sort technique. So far I've got the basic code running, but something is not right. I can tell the algorithm is wrong but cannot fix it, please help. [CODE]int bubble_sort(char **words, int num_word) { int …

Software Development algorithm c
Member Avatar for woozyking
0
641
Member Avatar for AnthIste

Hello there. I am very new to C++ and still rather new to programming (Im only in high-school). I am trying to make a decision based game that runs in a cli to just get going with the language syntax somewhat. So far the game is working, and I made …

Software Development c++
Member Avatar for Sturm
0
169
Member Avatar for prushik

Ok, I'm trying to write a little game in c++ using very simple graphics. not opengl or anything like that. Everything compiles fine (There are some warnings, i know how to fix them im just lazy, ill do it later) all of my code worked perfectly until i added the …

Software Development c++ opengl
Member Avatar for iamthwee
0
101
Member Avatar for sunil_kumar

#!/usr/local/bin/perl #check_oracle# use strict; use DBI; use Net::SMTP; $ENV{'ORACLE_HOME'} = '/app/oracle/product/9.2'; my $errors; my $total = 0; check_oracle(); if($total > 0) { my $mailer = Net::SMTP->new("142.1.0.1"); $mailer->mail('dpr-prod@repl1.newport.net'); $mailer->to('root'); $mailer->data(); $mailer->datasend("Subject: DPR database"); $mailer->datasend("\n"); $mailer->datasend($errors); $mailer->dataend(); } sub check_oracle { my $username = '######_@@@@'; my $password = '@@@@'; my $tnsalias = …

Software Development oracle perl
Member Avatar for KevinADC
0
98
Member Avatar for Alexbeav

Hi all I'm studying C and I have to do an exercise that requires me to open a file and count the number of times a letter occurs,either small or capital. For example,I have a text file in C:\text.txt with the contents "World In Conflict".So in my example the letter …

Software Development c gui
Member Avatar for iamthwee
0
503
Member Avatar for veronicak5678

Hello- I need to do a selection sort on two different 2d arrays, sorting by the last column of one of them (thirdarray). The first column of thirdarray is the effective column size for the first (morearray) array. I am so confused. I cant find any examples to help me. …

Software Development c++
Member Avatar for veronicak5678
0
110
Member Avatar for helixkod

This is the current assignment: Write a program that determines which of 5 geographic regions within a major city (north, south, east, west, and central) had the fewest reported automobile accidents last year. It should have the following two functions, which are called by [I]main[/I] [I]int getNumAccidents()[/I] is passed the …

Software Development c++
Member Avatar for Lerner
0
280
Member Avatar for teppuus

Hello, I am trying to call two functions: one that pulls data from a file and stores into a linked list, and one that displays this data to the screen. I pulled my code out of the functions and created a new file and included everything in the main function, …

Software Development c++ linked-list
Member Avatar for teppuus
0
162
Member Avatar for shantuli

hi, can anyone pls find out the problem of my code. Code: public class binarysearch { public static void main ( String[] args ) { int[] array = {2,2,10,20,55,100}; int target = 2; int left = 0; int right = array.length - 1; int mid = -1; while ( left …

Software Development java
Member Avatar for ChaseVoid
0
195
Member Avatar for pri_skit

I have written a CString Object into Text file by using : f.Write (&FileName,FileName.GetLength());//FileName is CString Object Now I want to Read CString object back How this could be done?I am using code : LPTSTR p = CurrentLanguageName.GetBuffer(11); void *g=(void *)p; f.Read (g,CurrentLanguageFileLen); CurrentLanguageName.ReleaseBuffer( ); //But this method don't work. …

Software Development c++ file-system
Member Avatar for pri_skit
0
121
Member Avatar for phylon

I am trying to read matrix data from file into a float vector the file has data like X = {1.0, 2.0, 3.0...........} Y = {3.4, 3.1, 3.4...........} I can read into vector strings. But I want to store the matrix names in a string vector and the matrix in …

Software Development c++
Member Avatar for Ancient Dragon
0
185
Member Avatar for rohit83.ken

removes comments from the given program and prints to the other file [CODE=c]#include<stdio.h> void main(int argc,char *argv[]) { FILE *in,*out; char ch1,ch2; int f=0; in=fopen(argv[1],"r"); out=fopen(argv[2],"w"); while(!feof(in)) { ch1=getc(in); if(ch1=='/') { if((ch2=getc(in))=='/') { while((ch2=getc(in))!='\n') { ; } } else if(ch2=='*') { while((ch2=getc(in))!=EOF) { if(ch2=='*') { if((ch2=getc(in))=='/') f=1; } if(f==1) break; …

Software Development c
Member Avatar for ithelp
0
71
Member Avatar for Max_Payne

I made this Data Table. The problem is when the outputs are different it will change the shape of the Table. I need some tips on how can i fix this problem. [code=cpp] [INDENT]double sum = 0; for ( int j = 0 ; j < 5 ; j++ ) …

Software Development c++
Member Avatar for ithelp
0
124
Member Avatar for qulit

Hello to all. I have a project which is scheduling system using vb6. I can't or don't know how to find the time conflicts of each subject at the given day and given professor. For example user select the section name then a combo box for selection of subject then …

Software Development visual-basic
Member Avatar for hopalongcassidy
0
148
Member Avatar for rogenie

why does this file outputs 516?? The value of numbers is being read from random.txt that has 200 random numbers in it. I was expecting this to output 200 and NOT 516.. whats up with this? [CODE] while (inputFile >> number) { //number of numbers on the file for (totalNumber …

Software Development c++
Member Avatar for rogenie
0
161
Member Avatar for Alexbeav

Hi all this is the 2nd exercise I can't seem to figure out how to do.Exercise goes like this : One method of encryption is this : We pair the letters of the alphabet to the numbers 0-25. Assuming we have a text "T" and a keyword "K" of "V" …

Software Development c encryption
Member Avatar for Dave Sinkula
0
145
Member Avatar for macy2323

how can i export a database from access to excel but in a tabular form(calendar form)?tnx!!!

Software Development visual-basic
Member Avatar for yello
0
183
Member Avatar for lucamarcus

Am a new c++ programmer. I refer to the code " Bouncing Ball" which is a GUI, now there is a rectangle created, i managed to change the color the rectangle in the main window and what my may problem is how to make the rectangle fixed and not only …

Software Development c++ gui
0
98
Member Avatar for 51al

hi...my name is agus ..i'm from indonesian...i'm new here... i want to ask something... i have project but i dont know about my wrong and solutions....this is mY project [code=c] void OpenGLInit(void); static void Animate(void ); static void Key_r(void ); static void Key_s(void ); static void Key_up(void ); static void …

Software Development c
Member Avatar for Ancient Dragon
0
74
Member Avatar for phylon

this is a small example from the gsl example online I need to get the value from the "&evec_i.vector " into a 4x4 dimensional array such that abc[4][4]= vector elements how can I do this ? those 16 values will create the 4x4 matrix [code] #include <stdio.h> #include <gsl/gsl_math.h> #include …

Software Development c
Member Avatar for dwks
0
140
Member Avatar for redaqen

Hey, again... I've got another assignment coming up and I'm having issues... again. Basically, my major stumbling block is figuring out how to set the int number = returned value of enterNewNumber. Also, is there any simple way I can store the digits of an integer as seperate numbers in …

Software Development c
Member Avatar for redaqen
0
137
Member Avatar for asilter

my program is written in c and compiled and linked with gcc. In normal way; i execute it by giving an argument after writing executable. [code] ./my_executable abc.dat [/code] and it works. i need to execute it in gdb debugger. how will i give this abc.dat argument to the gdb …

Software Development c
Member Avatar for dwks
0
100
Member Avatar for Justmehere

Can anyone tell me what the purpose of C functions which start with "__" ? Also another question is the same use of the "__" in defines like #define __HTTP_VERB_GET "GET"

Software Development c
Member Avatar for dwks
0
120
Member Avatar for koketa

Hello eveyone, I am kindda new to daniweb. I was hoping that someone would give me some hints on where to put the running total and how to quit once the user types 0 for hours parked(my teacher asked for this feature) I would enormously appreciate the help! A parking …

Software Development
Member Avatar for koketa
0
161
Member Avatar for jliu66

Hi, My friends, I am new to python. I try to figure out how python knows the end of loop or the end of a block of codes in while... else code Here is the example: while E: Bt else: Bf here if Bf have 20 lines of code. How …

Software Development python
Member Avatar for Lardmeister
0
119
Member Avatar for omagebi

please help. im writing an app that will send and receive sms using vb.net. i dont know how to start

Software Development vb.net
Member Avatar for flo-0001
0
76
Member Avatar for Paulville

Hi People I'm a newbie in c, I learn in c++, but I don`t really know to much. A friend make a code in c, working in a linux pc. And works perfect. I normally work in Micorsoft Visual Studio, but this c code, seems not to work well (88 …

Software Development c visual-studio
Member Avatar for Salem
0
160
Member Avatar for greglobal

Does anyone have a solution/c++ code to make bmp images transparent on the fly without having to carry out 2 bitblt operations with the image and it's mask ? We want to develop a game in which there are many moving objects which have to be rendered transparent at new …

Software Development c++
Member Avatar for JRM
0
100
Member Avatar for rohit83.ken

this code removes comments please help in correcting the code //Program to print a file by removing Comments #include<stdio.h> void main() { FILE *fp; char ch; //clrscr(); fp=fopen("temp.txt","r"); while(1) { ch=fgetc(fp); if(ch==EOF) break; else { if(ch=='/'){ ch=fgetc(fp); if(ch=='/') { while(1) { ch=fgetc(fp); if(ch=='\n') goto label; } } if(ch=='*') { while(1) …

Software Development c
Member Avatar for Salem
0
205
Member Avatar for atrix415

I am trying to print this to a dialog box. The code prints to console and prints, 1,2,3,4....12 to the dialog box. Can someone give me some advice on printing to a dialog box the verses to the dialog? [INLINECODE] import javax.swing.*; // program uses class JOptionPane public class TwelveDays …

Software Development java java-swing
Member Avatar for masijade
0
441
Member Avatar for wegdan

i generate a jar file for my project but when i try to run it by d-clicking it i found this massage java Virtual Machine Launcher could not find the main class.program will exit

Software Development java
Member Avatar for peter_budo
0
116
Member Avatar for satish.paluvai

1)I need to compare two directories .if the files which r not same in the two directories i want to list them in a new text file can anybody help me solving this question 2)how to write in a file in a String format using java? satish.paluvai

Software Development java
Member Avatar for masijade
0
104
Member Avatar for acwbrat

I am new to Daniweb and I need some help with my programming code in Unix. I have written an if-else statement for Bash Scripting and it doesn't work. I have been told that variables would help with my code but I still don't see my program working. I'm suppose …

Software Development shell-scripting unix
Member Avatar for masijade
0
84
Member Avatar for acwbrat

How do I change my file extension from me.cpp to me.out or me.cpp to me.exe using Bash scripting. Thanks!

Software Development shell-scripting
Member Avatar for masijade
0
115

The End.