49,761 Topics

Member Avatar for
Member Avatar for efigen

I have been trying to write this code that calls a text file in the command line, it then reads the file and if the file has integers that look like this (1+2+3+5)it takes there sum and outputs it into a different text file, if it looks like this (1+2 …

Member Avatar for WaltP
0
151
Member Avatar for oscargrower11

I'm used to c++ along with an open database (switched from mysql to postgres not too awful long ago.) A new job I'm looking at taking focuses heavily on .net along with SQL Server. As such, I've been looking into the .net framework and what I can't seem to figure …

Member Avatar for Ancient Dragon
0
171
Member Avatar for coolbeanbob

Hello, This is my first time using vectors. The code below creates a vector of size 30, but when I run the program (which loads 30 integers into the vector), the last integer in my data.txt file does not load into the vector. When I use a vector of size …

Member Avatar for NathanOliver
0
159
Member Avatar for triumphost

[size=10]The problem is the below code.. I created my controls.. The thing is that when I press the button, the edit control shows up on top of all controls except for the button that was pressed.. then if I move the mouse, all the other buttons under it, show up …

0
90
Member Avatar for seamus400

I was wondering if anyone could help me compile code which will actually work for my comiler. I've found many examples and two good references for... keyboard [url]http://www.codeproject.com/KB/system/keyboard.aspx[/url] and mouse [url]http://msdn.microsoft.com/en-us/library/ms646260[/url] ...but have never actually gotten a working version to run and therefore haven't been able to fiddle around with …

Member Avatar for seamus400
0
1K
Member Avatar for stinkypete

I am trying to write a multi-window text editor. I have a Page Control containing 20 pages, and each page (tab sheet) contains an instance of my editor. Which works mostly ok, except I sometimes get weird results when painting my editor window. The attached code is a greatly cut-down …

Member Avatar for stinkypete
0
243
Member Avatar for Coffee_Table

I am trying to run what i thought was a pretty basic program to solve a problem concerning strings (besides the point). It turns out that my algorithm works properly but i am stuck on a detail; the following segment of code is the problem: [CODE] int cases; string line; …

Member Avatar for Coffee_Table
0
587
Member Avatar for hondros

I posted a while back ago on making directx work in classes. I'm having more issues now. On line 125 (system.cpp), when in debugging, it tells me that it has an access violation. I googled the issue, and someone had said something about initializing the pointer, but that is taken …

Member Avatar for hondros
0
194
Member Avatar for Hajira Khanum

i have tried to write a code, but i have a problem with the play() module where the message "one Row Completed" is not being displayed. Please help me with this:icon_confused: [CODE=c++]#include<iostream.h> #include<conio.h> #include<stdlib.h> class bingo { public:int a[5][5]; void input(); void check(); void play(); void comp(); }; void bingo::input()//input …

Member Avatar for tajendra
0
240
Member Avatar for narendra_kuma

[CODE]#include <iostream> #include "stdlib.h" using namespace std; struct var{ int a; int b; int result; }; void adD(var&); int main() { int a; int b; cout<<"please ente the value a ==== "<<endl; cin>>a; cout<<"please ente the value b ==== "<<endl; cin>>b; var v1; adD(v1); system("cls"); cout<<"the value of result == …

Member Avatar for tajendra
0
101
Member Avatar for saboteur

I have this code for solving eight queens problem. There are 92 solutions but there are only 12 unique solutions by rotating/inverting. I cant seem to figure out how to make the program show only 12 unique solutions. Can someone help me getting that code? [CODE] #include <iostream> using namespace …

Member Avatar for raptr_dflo
0
133
Member Avatar for Onlineshade

This is my code.... [CODE] #include<iostream> #include<conio.h> using namespace std; int main() { int t,i,j,k,m,n,o,q=0,a,b,c; cin>>n; cin>>k; i=n+1; j=k-1; for(a=n+1;a<=k-1;a++) { for(b=i;b<=j;b++) { m=a*b-n; n=a-n; o=b-n; t=n*o; c=m%t; if(c==0) { m=0; n=0; o=0; q++; } else { m=0; n=0; o=0; break; } } } cout<<q; getch(); return 0; } [/CODE] …

Member Avatar for raptr_dflo
0
51
Member Avatar for SilentCoder

Hi, i am trying to merge Folders into File.extension and i was wondering how would i be able to do this. Basically i am trying to merge all files in a folder to one File.extension, for example: i have folder called Client, i have few files in Client folder: Notice.inc, …

Member Avatar for raptr_dflo
0
179
Member Avatar for Vusumuzi

I am currently studying C++. I have an assignment of which I have completed. but need to verify if I'm on the right path with my answers. I have attched the assignment question herein. Thank you guys, you are far to kind.:

Member Avatar for Ancient Dragon
0
40
Member Avatar for Soulreaverx7

I have to get this program to read from a text file and write the data to another text file. The problem i'm having is the format. It's typing everything on one line [CODE]#include "stdafx.h" #include <iostream> #include <fstream> #include <iomanip> using namespace std; //reading data from a file int …

Member Avatar for mrnutty
0
135
Member Avatar for kutuup

Hi all, I'm just working on a little Allegro 5 puzzle game for a bit of fun and practise between jobs. Anyway, I have a bit of an optimization issue. It's a board based game where you have an 8x8 board with each square having a value of 0-3 representing …

Member Avatar for kutuup
0
254
Member Avatar for Arkrothe

What will happen? Here's a code that i tried, it works but i don't really get what's actually happening or how many instances of the static test t are getting created. [CODE] #include<iostream> using namespace std; class Test { public: static Test t; void hello() { cout<<"this line shall be …

Member Avatar for Arkrothe
0
237
Member Avatar for Onlineshade

How to do graphics in visual c++. Is it possible to run a graphics program in c++?

Member Avatar for m4ster_r0shi
0
164
Member Avatar for Celcion

Hello, currently new to C++ and learning the ropes. I'm trying to create a simple database-like program, but the following code doesn't output any meaningful data. The program compiles fine, though. The rest of the program is still under work, so I'm just posting the relevant parts which I think …

Member Avatar for Celcion
0
115
Member Avatar for emreozpalamutcu

I'm working in this project that has a feedback form and in this feedback form there is only body, so it doesn't ask for subject and who it's from. And all the messages send from will go to a custom mail account, for example [email]Example@custom.com[/email] How can I do this …

Member Avatar for cent91
0
597
Member Avatar for triumphost

Kk so I've been using these functions for quite some time and everytime I write a new program and decide to use them, I have to open up old ones and copy paste them with a whole bunch of include n crap. I decide I'd try to make a DLL …

0
72
Member Avatar for crapgarden

This code: [CODE] int array1[5] = {1, 30, 90, 40, 3}; char array2[] = {125, '}'}; cout << array1 << endl; cout << array1[0] << endl; cout << array1[1] << endl; cout << array1[2] << endl; cout << array1[3] << endl; cout << array1[4] << endl; cout << array2 << …

Member Avatar for crapgarden
0
97
Member Avatar for aspirewire

I'm very new to programming and I'm trying to make a program to compute the circumference of a circle when you give it the radius, but I keep getting "fatal error LNK1169: one or more multiply defined symbols found" whenever I think I fix it, it just says the same …

Member Avatar for Ancient Dragon
0
354
Member Avatar for IndianaRonaldo

hi all guys, I have just started CURL programming in vc++.But I don't have a good place to start reading more about it.I do understand the basics of it,but I want a procedural tutorial to learn more about it. Is there any proper site to learn from basics to higher …

Member Avatar for IndianaRonaldo
0
186
Member Avatar for sirknieghf

hi i got a problem when try to use pointer and struct..somehow ive manage to compile my coding but the main prob is that the output is not what ive keyed in.. [CODE]#include <iostream> #include <conio> #include <string> #include <stdlib> void printtable(); void input(); void calculate (); void scorecard(); void …

Member Avatar for sirknieghf
0
389
Member Avatar for Triarius

Hi! I have recently started using linux and I was recommended gcc compiler. I have written a basic program just to see if it works. And it doesn't. I am trying to compile it with Terminal, and with the following command :[CODE]gcc ~/Desktop/C++/test.cpp -o testing)[/CODE] My program it responds with: …

Member Avatar for Triarius
0
297
Member Avatar for MrAppleseed

-First post Woot!- Alright, here's the problem; I'm building a _very_ simple Terminal-like program. The only problem is that in a normal Terminal (be it in Linux or Windows' "Command Prompt") there is no definitive number of inputs that you can input, for instance; you can either type "dir", or …

Member Avatar for Narue
0
134
Member Avatar for c++creator

Umm I created a code which will create many results with specific ints(integers).I use Code::Blocks as my compiler.The code works inside the compiler,but when I go to the saved folder and run the batch file this is what happens-I enter a number and press enter and it simply closes itself!@What's …

Member Avatar for c++creator
0
177
Member Avatar for IndianaRonaldo

VC++ 10 gives error when libraries and headers related to libcurl are added to project.Even if curl.h is not included in the code, C2065 undeclared identifier _SH_DENYNO //this is in xiosbase... the above error comes. Is there a problem as there is no libcurl version for vc++ 10? ....libcurl works …

Member Avatar for raptr_dflo
0
251
Member Avatar for Basteon

So, I want to save an HBITMAP to different image file formats like BMP,PNG and JPEG. I believe that the most simple way to do it is by using GDI+. So here is what I came up with. [CODE]Gdiplus::Bitmap bmp(hbmpImage,(HPALETTE)0); CLSID pngClsid; GetEncoderClsid(L"image/png", &pngClsid); bmp.Save(L"D:\image.png",&pngClsid,NULL);[/CODE] The problem is that it …

Member Avatar for raptr_dflo
0
1K

The End.