General C++ Programming - August 2011 (Page 9)

Code Stucks while running! need some help!
 
Hi, I have a code that passes compilation, but stucks while running with no error message! main.cpp #include <iostream> #include "Tree.h" #include "Mo...
[4 replies] Last: yea, i fixed the return issues. but i still have have a problem with... (by aymanbah)
error C2995 while compiling
 
Hi, 1) When i`m trying to compile this, i`m getting this error: node.h(48): error C2995: 'std::ostream &operator <<(std::ostream &,const Node<T> &)' : functi...
[1 reply] : 1. First is because when you have different types for T, operator<T2> ... (by hamsterman)
Need some help please!
 
Why i`m getting this erroR ? error C2955: 'Tree' : use of class template requires template argument list template <class T> Node<T>* Tree::findNode(const ...
[2 replies] Last: Oh, thnx man ;) (by aymanbah)
by HenriK
Templates - What is wrong with this?
 
Hi there! I was dealing with templates this time. Pretty neat concept, I have to admit. However, there is a problem: an error comes when I try to something l...
[6 replies] Last: What part of that model is flexible? About the error, I feel that it... (by HenriK)
by lyceum
Template & Inheritance
 
#include <iostream> class Base{ public: Base(){} virtual ~Base(){} virtual void show() const { std::cout << "Base::show()!" << std::endl; } }; class A:...
[3 replies] Last: #include <iostream> class Base{ public: Base(){ std::cout << "Ba... (by lyceum)
using sscanf for double or long
 
hi, Can I use sscanf for type double. I am using it such for int: std::sscanf(as.c_str(),"%d\t%d\t%d",&a,&b,&c); thx!
[2 replies] Last: thx Duoas! (by itcplpl)
how to send an email using C/C++ with Auth Gmail Account
 
Hello, I want to simply send email using C or C++. I have tried so many examples and sample codes but they didn effect.. I hv tried to use the google smtp ...
[5 replies] Last: So your problem is not your program but more on the computer that exec... (by sohguanh)
by ksm092
Extract a value(eg. argv[1] perhaps) from a line in a vector
 
I am trying to sort a vector of strings in order (one line consists of various strings e.g. 12 10 2010) and was wondering if I would be able to extract individu...
[3 replies] Last: Assume you are using C++ string you can use their member functions to ... (by sohguanh)
c++ insert struct on set
 
hi all, I am trying to insert a structure into a set but when I compile I am getting an error. typedef struct pairData_ { int index; string data;...
[5 replies] Last: Assume operator << is for output. typedef struct pairData_ { int ... (by sohguanh)
can't translate objects/primitives along z-axis with opengl
 
I can translate objects along the x and y axis by passing variables to them that are incremented or decremented by 0.05 upon pressing the a,d or space bar. But ...
[1 reply] : You need to setup the projection matrix. The projection matrix essenti... (by shacktar)
3D Rendering without openGL or other libraries
 
I wanted to make my work on a 3D rendering engine available for somebody who might find it useful . The whole thing is one header file : you enter screen heigh...
[2 replies] Last: That's why I mentioned vector graphics - If you want to draw lines (sa... (by Petko Ditchev)
C++ Copy a string to Clipboard
 
:D Hello everyone, I am making a program where the user types in a string and then the string is saved to the clipboard, but I am not quite sure how. I have ...
[12 replies] Last: Thank you so much for all your great help and effort :D The code works... (by Muhasaresa)
by DrNote
Newbie
 
Hi everyone, Please help me. I want to become a programming. I'm still student. Anyone can tell me how to learn C++ from the start and which software I need ...
[1 reply] : For the a head start http://www.cplusplus.com/doc/tutorial/ http://www... (by TheMassiveChipmunk)
Heap corruption when initializing pointer
 
Hello, I'm working with a metadata library for audio files. But I have a problem with some heap corruption. But the funny thing is that it happens when I initi...
[7 replies] Last: I know goto is not good to use in C++ but I need speed for my functio... (by Disch)
How to use different structure elements generically inside a function
 
Hi, I want to be able to pass variables pointing to different data structures, as arguments to a finction and have the function do various operations on the ...
[1 reply] : Research polymorphism. (by webJose)
I Need C++ Help
 
So, in a game I'm making, the players have the option to invest their money, using said code: if (money >= 200) { ...
[10 replies] Last: Code::blocks is a free and open source IDE for C/C++. I think there's ... (by closed account 967L1hU5)
by Zeeb
c++ Newb while loop
 
power = 3; check = 2; while (power <= 23) { nämnare = power * check; täljare = pow(sinp1, power); serie = täljare / nämnare; power = power...
[7 replies] Last: The values in an integer array: int array ; will not default to anyt... (by anonymous23323124)
How Do I Obtain The Latest OpenGL?
 
OpenGL isn't in the form of an SDK. So how do I obtain OpenGL 4.0? Wazzak
[2 replies] Last: Simple enough. Thanks, Creekist :) Wazzak (by closed account zb0S216C)
Random extra characters in string to char conversion
 
Anybody know why the conversion of string "CT/C1.dcm" to char[string.size()] is going to "CT/C1.dcmx?2?" ? Here is my output: Reading File: CT/C1.dcm of...
[2 replies] Last: That definitely helped. Thank you. (by jmadsen)
Find largest prime factor?
 
I am able to do this for smaller numbers, but as soon as a get to larger numbers my program doesn't show output. I know my algorithim works, but how do I make i...
[2 replies] Last: Nevertheless, on modern systems an unsigned long long will easily ho... (by Duthomhas)
August 2011 Pages: 1... 7891011... 29
  Archived months: [jul2011] [sep2011]

This is an archived page. To post a new message, go to the current page.