49,761 Topics

Member Avatar for
Member Avatar for megabutt

Hello, I am learning the ropes here. I have a non-code question, strictly conceptual. How (generally speaking) do I design my project in Visual Studio C++ to acheive the flow in the block diagram, and specifically how do I access Var A and Var B from Main.cpp if they are …

Member Avatar for megabutt
0
175
Member Avatar for Mac.Z

Hello, I'm getting started with C++ and have some questions about the variable types: 1)The size of a variable type, is it defined by the compiler or computer or both? and why it differ from one to another? 2)Isn't [I][B]short int[/B][/I] supposed to hold smaller data than [I][B]int[/B][/I] can hold …

Member Avatar for John A
0
108
Member Avatar for herykl

I've been banging my head for a bit now trying to figure out why this isn't encrypting properly. Unfortunately, there are not a lot of resources out there for using wincrypt.h. I prefer to use the windows api's over having to use some external library to do the same task. …

0
54
Member Avatar for Matt Tacular

I have some code that generates numbers, and I wish to add them to some kind of list, I did research and an array seems to be close to what I want, but I can't find how to add a generated variable to it. Or is there some other kind …

Member Avatar for Matt Tacular
0
72
Member Avatar for Tauren

Well, is there a book I can get that teaches me all about How to create a game engine? Like how to create a game engine and stuff?

Member Avatar for John A
0
121
Member Avatar for CurtisBridges

Exceptions -------------------------------------------------------------------------------- I am working on a class project as layed out by the instructor. This is in conjunction with Chapter 13 (Exceptions) from the book How To Program in C++ by Deitle 4/e. I am at a total loss on this subject. I thought that catching problems was up …

Member Avatar for John A
0
121
Member Avatar for Matt Tacular

First of all, let me exaplain that I only really know python. I thought I would give c++ a try and since then (about two days ago), I have read a few tutorials and have made a guess number game. I thought I would be able to rewrite one of …

Member Avatar for Matt Tacular
0
238
Member Avatar for CurtisBridges

[B]Exceptions[/B] I am working on a class project as layed out by the instructor. This is in conjunction with Chapter 13 (Exceptions) from the book How To Program in C++ by Deitle 4/e. I am at a total loss on this subject. I thought that catching problems was up to …

Member Avatar for Dani
-1
103
Member Avatar for raydogg57

I need help developing a program that acts as a command line parser. Essentially, my program needs to ask the user to input a command line: eg - A+B=C. It will then output the following: A + B = C. Although this seems basic, my program needs to recognize different …

Member Avatar for ~s.o.s~
0
136
Member Avatar for tradfreak

hello :-) I'm Sean and currently a 3rd year BS Business Admin. Major in Management Information Technology student... due to my limited programming skill... i know this would be a simple programming problem to you guys out there so i would like to get inputs on how am I to …

Member Avatar for fesago90
0
107
Member Avatar for FireSBurnsmuP

Well, I guess I'm just here out of curiosity. I would like to know how one would go about outputting an image file. I thought that maybe you could declare an [inlinecode]ifstream[/inlinecode], and try to read it in, but I don't know how I'd go about that either... Any ideas? …

Member Avatar for John A
0
177
Member Avatar for amishosh

Hi! Even when I use windows versions of C++ compilers (Visual studio or Borland) when I compile my program it opens up in a DOS window. Is VB the only way the program will open up in a windows like window? Thanks, Ami

Member Avatar for fesago90
0
121
Member Avatar for megabutt

Hey folks, I thought that recently I transitioned form NOOB to novice until I had this question. Oh, well. Why can't I create an executable in Visual Studio 2005? I have my Win32 project code debugged and it builds a library object file, not .exe. I am in release mode …

Member Avatar for John A
0
97
Member Avatar for loslos

[code]#include <iostream> #include <fstream> #include <cctype> using std::fstream; using namespace std; int count[26]; int main(int argc, char *argv[]) { char ch; ifstream infile("c:\\a.txt") ; if ( !infile ) { cerr << "File could not be opened" << endl; exit( 1 ); } int i; for(i = 0; i <26; i++) …

Member Avatar for loslos
1
112
Member Avatar for Harshita_garg

Hi All!! I am relatively new to C++ programming so please forgive me if my question is very basic or silly. I am trying to read files in C++. It opens text based files properly but doesnt open csv files , though I am saving them in the same directory. …

Member Avatar for Harshita_garg
0
1K
Member Avatar for keeray

i can't run my program bcoz of this error.. [code=cplusplus] #include<iostream> #include<math.h> #include<string.h> #include<iomanip> { int main() int x,y,z,r; float a; char ch; cout<<" enter amount"; cin>>x; cout<<" enter number of years to be paid"; cin>>y; cout<<" enter the rate"<<endl; cin>>z; r= z/100; cout<<" what would you like to compute?"<<endl; …

Member Avatar for Dave Sinkula
0
168
Member Avatar for Caped Sam

Hi all. I recently downloaded and installed Bloodshed Dev-C++ and have begun going through C++ tutorials and whatnot. I'm very green on the whole C++ thing. My current problem is that I want to use a .cpp file that someone else wrote that includes some so-called 'standard header' files, one …

Member Avatar for Ancient Dragon
0
283
Member Avatar for Rickenbacker360

Hello again, I'm slowly getting better, I would never have been able to get this far before, but I'm stuck. Here's what my program is supposed to do: [COLOR=#000000]1. [/COLOR][COLOR=#000000]Develop a C++ program that uses a while structure to input the miles driven and gallons used for each tankful. The …

Member Avatar for Rickenbacker360
0
113
Member Avatar for fesago90

[B]EDIT:[/B] Again, after searching for some time and not finding any answers then asking here and going back to experiment a bit with my code, I figured out the answer just by trial and error :| Hi! My current homework assignment requires me to read some info from a file, …

Member Avatar for Dave Sinkula
0
5K
Member Avatar for kubi

Hey Friends, Can you help me to code a program that sends email in C++? Maybe by Telnet or another way :S i dont know anything about this. Thanks.

Member Avatar for jwenting
0
82
Member Avatar for RaCheer

I have written a program that allows the user to insert scores and the program then provides the average score, the number of scores entered, the amount of each letter grade, and the highest and lowest score. I've also used a sentinal to exit. I'm new to C++ and this …

Member Avatar for ~s.o.s~
0
153
Member Avatar for fesago90

;) Hey guys, I have another simple question today: Lets say I have a structure: [code=c++]struct Info{ string name; string id; double telNum; }; //.... Info person; //....[/code] Now, if I had a function in which I told it to output one of the elements in the structure, how would …

Member Avatar for Ravalon
0
134
Member Avatar for mattyd

Hello: I am interested in understanding recursivity; I have not knowingly used this much in my programming. I am reviewing certain areas of OOP in order to learn more and better about areas that I may not be[I] fully[/I] understood yet. Recursivity is one of these areas. I understand the …

Member Avatar for Infarction
0
183
Member Avatar for adhetola

can anyone help me with the simplest c++ code for solving the sudoku puzzle, without testing for correctness/uniqueness of entries?

Member Avatar for WaltP
0
82
Member Avatar for megabutt

Problem background: I am writing a Visual Studio C++ app referencing an Api library provided by a third party. Problem: after calling the API function I am getting a 2059 "syntax error" that I don't understand. I have added the code exactly as the third party documentation has described. Error:c:\documents …

Member Avatar for megabutt
0
133
Member Avatar for 2nick82

How to generate 50 distinct numbers in an array? I have the code for generating 50 numbers but thay are not different. I get same number sometimes twice or three time. Here is my code: [code=c] #include <iostream> #include <cstdlib> #include <ctime> using namespace std; int num; int main() { …

Member Avatar for Ravalon
0
111
Member Avatar for Firestone

I wrote this code to produce a fibonacci seqeunce to a cretain number. However, when you get to a certain number, it starts producing negative numbers, and I don't know what to do. [code] #include <iostream> #include <stdio.h> using namespace std; int main() { long lMax; lMax = 0; long …

Member Avatar for Salem
0
131
Member Avatar for localshredder

Does anyone know a good c++ compiler equivalent for MinGW on Mac OSX (10.4x)? I just started a class that requires the use of MinGW, but since it's native windows I obviously can't use it. And just to clear the air, I would rather not install Boot Camp just to …

Member Avatar for Madd the Sane
0
15K
Member Avatar for RossSCann

This CreatePen call is failing after repeated calls HDC hDC; hDC=GetDC(hWnd); [COLOR=#008000]apen = CreatePen(PS_SOLID, 1, colorG[7]);[/COLOR] [COLOR=#008000]oldPen=(HPEN)SelectObject(hDC, apen);[/COLOR] [COLOR=#008000]...line drawing stuff...[/COLOR] [COLOR=#008000]ReleaseDC(hWnd, hDC);[/COLOR] [COLOR=#008000]Apparently a memory leak even with the release[/COLOR] [COLOR=#008000]C++.net is the compiler[/COLOR] [COLOR=#008000]Any thoughts?[/COLOR]

Member Avatar for Salem
0
90
Member Avatar for jan1024188

Whats better? C++ or VB? Im sure C++ is much more powerfoul and portable than VB...what do you think?

Member Avatar for Ravalon
0
312

The End.