General C++ Programming - January 2009 (Page 3)

reading and storing configuration data.
 
How do I read from a configuration .ini file to my .cpp file and then store the data with a .h file?
[3 replies] Last: You can just open a new file and write to it, just make sure you close... (by firedraco)
C++ if problems
 
#include<iostream> #include<string> using namespace std; int main() { string input; int money = 0; int game = 1; while(game = 1) ...
[1 reply] : while(game = 1) should be while(game == 1) ~psault (by psault)
C++ grpahics on a mac PLS
 
My school computers use Borland 5.0 and I have used the BGI demo and functions such as putpixel(), getmaxx(), getmaxy(), initgraph(), closegraph(), etc... for...
[7 replies] Last: 2+ for SDL, Use lazyfoo.net for a guide on how to set it up (by Mythios)
[SOLVED]Old Conio.h Header
 
Just wondering if anyone knows where I can find out all they key values for the conio.h header file. I know for example ENTER = 13 and ESC = 27. But I can't fin...
[6 replies] Last: Ah, Thanks for that helios - I see what you mean. (by Mythios)
bitvectors
 
Looking for help with understanding: "A mask can be used to access an individual bit of a byte. Suppose, for example, that we want to access the third bit fr...
[3 replies] Last: You got it. (by seymore15074)
[SOLVED]Maximizing A Console Window
 
Ok, so I don't want my console app to run in full screen - but I would like it to run maximized. Only problem is I'm not to sure how to pull it off. void ...
[1 reply] : Fixed: void MaximizeWindow() { CONSOLE_SCREEN_BUFFER_INFO info;... (by Mythios)
How Do i cast from a char to int?
 
Hi im really new to c++ and im taking a college course on c++ and my assignment requires i cast from a char to int how do i do that my current code is this its ...
[3 replies] Last: Please use proper puncuation. It is very difficult to sort through a ... (by kempofighter)
[SOLVED]Taking a letter off the end of a string?
 
Hey guys, Just wondering the simplest way to take a letter off the end of a string. Etc... std::string myString; std::cin >> myString; std::cout << "...
[7 replies] Last: Making use of the conio.h is my goal. (by Mythios)
by jrohde
Variable declarations
 
Hello all, Any gain in performance by declaring multiple variables on the same line, or does the compiler treat them exactly the same? e.g.: int x, ...
[2 replies] Last: Compiler would likely generate the exact same code. But that would als... (by Zaita)
Array Values
 
i have set up an array that is printed to the screen. it consists of 4 columns and 6 rows, all of which are set to 0. i need to change these values seperat...
[2 replies] Last: @Scipio: Wel (notice my spelling mistake too ;)), first of all, there ... (by Zaita)
Inner Product Implementation in C++
 
Dear all, Is there such existing implementation? Suppose I have three matrices MATRIX 'X' 1 2 3 4 MATRIX 'Y' [,1] [,2] [,3] [,4]...
[1 reply] : Try: http://www.boost.org/doc/libs/1_35_0/libs/numeric/ublas/doc/index... (by Zaita)
access to dynamic allocated array
 
Hi, I am having trouble with accessing dynamic arrays. I need to fill up two arrays in warpImage obj, then use them in another obj by calling getX(index) and ...
[5 replies] Last: try these: class confidence { public: confidence(); v... (by ReeV)
password: exit after 3 wrong code
 
How can i make a program that goes like this???? >>program will ask the user to input the password... after 3 wrong password, the program will be terminated....
[4 replies] Last: It is pseudo code to give you the idea of the logic behind what you ... (by closed account z05DSL3A)
loading effect
 
how can i make a loading effect in c++? for example: loading...// the 3 dots are apearing one-by-one continuesly [a bar loading here] 1% can you ple...
[6 replies] Last: Hah sorry about that - either way hope what I gave you helped. If not ... (by Mythios)
password as ********
 
uhm.... excuse me but can you please help me? i'm having trouble with making password in c++.... the condition goes like this, while the user is entering a pass...
[2 replies] Last: oh... thank you! ^-^ (by euiane09)
by z00mit
SAFEARRAY to String
 
Hi Guys, I am trying to serialise a SAFEARRAY to a string. I tried this: SAFEARRAY* content; ... CComVariant value( content ); value.ChangeType( V...
[1 reply] : SAFEARRAY* content ; //... std::string content (temp); //<-- What?... (by helios)
Read a file and store strings into arrays?
 
Hello. I am new to this forum! Hopefully I can get some help with some basic programming stuff. Im a working on a project....Here are the requirements 1)Rea...
[3 replies] Last: I think his question is: How would you go about creating a base and d... (by cwalker)
How to make compiler evaluate a user input expression
 
Lets say I have the expression 3*(5+2); if that expression were in the source code of a C++ program the compiler would evaluate it to be 21. Is there a way I ca...
[2 replies] Last: wow thanx so much!!! (by platypus1130)
Is this possible without an external library
 
How can I write some code to handle key presses without using an external library? Not sure if this is even possible. Just I can do it using something like lets...
[3 replies] Last: On windows you can use. By using a message loop your able to continual... (by Zaita)
Skipping lines with specified character
 
Dear all, I have a dataset that looks like this: AAAAACTGC ..ACTCGGG ACGGGGAAA ......... ACGGG...G AATGAAAAA What I want to do is to skip all ...
[2 replies] Last: if ((int)DNA.find(".") > 0) continue; (by Zaita)
January 2009 Pages: 12345... 11
  Archived months: [dec2008] [feb2009]

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