49,761 Topics

Member Avatar for
Member Avatar for ticktock

Hey all, I am currently trying (desperately trying if I might add) learning how to use GLUT for school. Our professor gave us an assignment to make a 2d tube of some sort, but I only managed to make a circle. The tube will be only displayed on its front …

Member Avatar for ticktock
0
314
Member Avatar for el33t

Hi, I have a doubt regarding inheritance of base class constructor by inherited class. I was recently going through some C++ online tutorial when I came across this piece of code: [CODE=c]#include <iostream> class Foo { public: Foo() { std::cout << "Foo's constructor" << std::endl; } }; class Bar : …

Member Avatar for caut_baia
0
192
Member Avatar for PixelExchange

Hello everyone.. When working with Visual Studio 2010, the "MessageBox" function displays chinese characters, instead of english ones. Example: I attempted to prompt a message to myself using the messagebox function, saying "Success!" However, the message box pops up a message in chinese, and not in english. I am able …

Member Avatar for PixelExchange
0
168
Member Avatar for jwxie

I am confused. Here is the source: [url]http://www.learncpp.com/cpp-tutorial/28-constants/[/url] [QUOTE] Literal constants Literal constants are literal numbers inserted into the code. They are constants because you can’t change their values.[/QUOTE] Why can't we change literal constant? I mean if we want to initialize something, let say [CODE]int x = 14;[/CODE] And …

Member Avatar for jwxie
0
94
Member Avatar for dadam88

I just started to get a grasp of classes. I can't find my answer anywhere, and I hope someone on here can answer it. I am trying to simlate a battle [B]USING CLASSES[/B] Everywhere I look on the net people in C++ don't use classes to simulate battles. You could …

Member Avatar for dadam88
0
107
Member Avatar for DaSpirit

Hey guys, I'm new here. I just started learning c++ and I'm having a few problems. I have looked for one online but I found none that really worked for me so I tried to make my own. I'm trying to make a constant frame rate at 30 frames per …

Member Avatar for DaSpirit
0
284
Member Avatar for gaurav_13191

Hi,I am new to daniweb and would like to know the error in this code [CODE] void initpoly(struct poly *p) { int i; p->noofterms=0; for(i=0;i<MAX;i++) { p->t[i].coeff=0; p->t[i].exp=0; } }[/CODE] I am not posting the entire program because it is lengthy.I am getting the error"Expected primary expression before token ;" …

Member Avatar for gaurav_13191
0
240
Member Avatar for mehak gupta

Hey,can anyone tell me how to invoke a new application/software using c++ or visual c++. Also, gor interfacing a gui with my c++ code,should i go for vc++?

Member Avatar for mehak gupta
0
257
Member Avatar for mavs123

oh my please help me..i;m making a simple code in c++ using dev c because i am exploring this language for my second year. i do not know why it will not display the output..i don't know how to use cin..[CODE]#include <iostream> using namespace std; int main() { cout << …

Member Avatar for harris21
0
108
Member Avatar for qqwushi12345

Below is my code: [CODE]#include "stdafx.h" #include "strlib.h" #include "simpio.h" #include "genlib.h" int _tmain(int argc, _TCHAR* argv[]) { int num1,nom1,num2,nom2,num3,nom3,num4,nom4; double nem1,nem2,nem3,nem4; string a,b,c,d; printf("Enter first name: "); a=GetLine(); printf("Enter games played for %s: ",a); num1=GetInteger(); printf("Games won for %s: ",a); nom1=GetInteger(); nem1=(nom1/num1)*100; printf("\n"); printf("Enter second name: "); b=GetLine(); printf("Enter …

Member Avatar for qqwushi12345
0
105
Member Avatar for fr0styh3rb

I am developing a payroll program for my programming class. I need to declare the Int as a double in order to produce the product for number of employees in a department times the average salary for each employee. Can someone take a look at me code and let me …

Member Avatar for arkoenig
0
118
Member Avatar for Nandu Das

I am a computer science student and i want to know how to create a c++ program to ping an ip address and check whether it is online or not?

Member Avatar for vijayan121
0
66
Member Avatar for gpleonar

The program needs to ask for n and then output the first n terms of the Fibonacci sequence. exp. n = 6 1, 1, 2, 3, 5, 8 1+1 =2 2+1=3 3+2=5 5+3=8 My origional program used a nested for loop. I am not sure if that is right to …

Member Avatar for harshmore
0
411
Member Avatar for cgcgames

Hey Everyone I am having troubles. i tried looking up how to make the main for invisable but i cant figure out how. i saw some examples but they made no scence to me. What i am trying to do is change from one form to another and hide the …

Member Avatar for ShadowScripter
0
187
Member Avatar for AkashL
Member Avatar for Ancient Dragon
0
74
Member Avatar for okwy

his is a follow up to the question I asked earlier and with the help of some people here I was able to start up with the function I want to write,but I am yet to complete it. Here is my earlier question: I have a series of files with …

Member Avatar for Adak
0
193
Member Avatar for Garrett2011

was the idea of nested functions considered to be useless during the time of developing older c++ standard, because its usage is basically covered by another concept like object-oriented programming; or it wasn't implemented just as a matter of simplification?

Member Avatar for arkoenig
0
531
Member Avatar for algoexpert
Member Avatar for Nick Evan
0
72
Member Avatar for jpeg

Trying to figure out how to write this program. I need some immediate help! Define a base class person that will contain universal information, including name, address, birth date, gender and identification (student, worker etc). Derive from this class the following classes: Student Worker Student_worker Add variable school for student …

Member Avatar for -ordi-
0
189
Member Avatar for thilangane

I'm trying to merge two trees. This is the recursive function: [CODE] void Merge(node *primary,node *secondary) { if(secondary != NULL && primary != NULL) { Merge(primary->left,secondary->left); Merge(primary->right,secondary->right); } else if(secondary != NULL && primary == NULL) { primary = new node; primary->action = secondary->action; primary->left = NULL; primary->right = NULL; …

Member Avatar for thilangane
0
90
Member Avatar for Jsplinter

Simply put I wish for text entered in one edit box to then appear in another edit box. I have created a MFC dialog and read many tutorials, but I'm still stuck. Here is my current DDX function: void Ctextentry23Dlg::DoDataExchange(CDataExchange* pDX) { CDialog::DoDataExchange(pDX); DDX_Text(pDX, IDC_EDIT1, name); DDV_MaxChars(pDX, name, 20); DDX_Text(pDX, …

Member Avatar for Jsplinter
0
534
Member Avatar for nbaztec

To avoid double postings kindly refer the thread here, since I couldn't make up, which forum was best suited. [URL="http://www.daniweb.com/forums/post1297528.html#post1297528"]http://www.daniweb.com/forums/post1297528.html#post1297528[/URL] Please do take part in the discussion. Regards, Nisheeth Barthwal

0
76
Member Avatar for siddharthsohoni

hi i have created a matrix of 9 edit boxes. 3x3... i want to change the background color of the edit boxes during their creation. how should i do that ? thanks in advance...

Member Avatar for sundip
0
70
Member Avatar for rObOtcOmpute

Basically I'm trying to use an array to store inventory data, and I'm a little (lot) lost with vectors and such. I feel a little guilty asking for help three times in a day, but alas the semester is winding down and I'm in a crunch. My class (or should …

Member Avatar for Ketsuekiame
0
5K
Member Avatar for Nathan Campos

Hello, I'm learning C++ and trying to build my own file zipper, because i like very much to work with zip files, but now i want to build my own zipper and it's so hard to find good resources to start. As you can see in my previous posts i …

Member Avatar for DevC+
0
187
Member Avatar for siddharthsohoni

i have created 9 edit boxes using MyEditBox->Create()... now when i click on button, the previous values should be erased and new values should be populated... how should i do that ? thanks

Member Avatar for jonsca
0
47
Member Avatar for mavs123

I would just like to ask if in declaring methods in your class at C++ you would always do this: [CODE]public: void ListInsert(position,item,success); void ListDelete(position,success); void ListLength(void); void ListIsEmpty(void); [/CODE] i am to create adt list using the basic funtions but i can't start..whew!

Member Avatar for mike_2000_17
0
116
Member Avatar for lmbdx

Hi, I've developed a console app and a win32 api GUI. The GUI is only used to get input file path and output file path specified by the user, as simple as that. I now want to pass those file path and call the functions in my console app to …

Member Avatar for lmbdx
0
572
Member Avatar for Dannyo329

Hey guys, is there anyway a C++ program will continue to execute and not pause when I run a program for it? E.g I've already got [CODE] system("iTunes.exe.lnk"); main(); [/CODE] It calls main after it executes the program, but it is paused until I exit iTunes, is there anyway to …

Member Avatar for sundip
0
137
Member Avatar for dolly_olaide

Hello, I am currently working on body detection and face recognition using OpenCV. But I want to create a GUI using Visual C++. I am unfamiliar with it, so I wanted to know if anyone has any tutorials or what can lead me into the right direction. Thanks in advance …

Member Avatar for Garrett2011
0
102

The End.