49,761 Topics

Member Avatar for
Member Avatar for ana_1234

Hey, May someone please explain to me why the rename function isn't working? result should display a 0 if the files were sucessfully renamed. it keeps returning a -1. [CODE] #include <iostream> #include <fstream> #include <iomanip> #include <cstdio> using namespace std; int main(int argc, char *argv[]) { bool Stats; char …

Member Avatar for ana_1234
0
242
Member Avatar for Celtrix

I'm not known to be a very memory friendly guy but after about 4 hours debugging my lua+sdl in C++ I finally figured out how to use threads but now I have another problem. I apparently have zero knowledge of memory manangement but thats kind of ok so I've narrowed …

Member Avatar for Celtrix
0
248
Member Avatar for tomtetlaw

I'm using VC++ 2010 Ultimate and I'm running a Windows 7 x64 machine. I have a function declared to be a dll export ([icode]__declspec(dllexport)[/icode]) and it builds without error or warning, but when I try to load that function with [ICODE]GetProcAddress[/ICODE] it returns NULL. I've looked inside the .exp file …

Member Avatar for tomtetlaw
0
159
Member Avatar for pseudorandom21

The worst thing about C++ in my opinion is trying to use a library (with VS2010 at least). It always causes me great pain, and usually I am not met with success. So, I'm trying to use the Magick++ library, which is a part of the ImageMagick program, and I …

Member Avatar for Celtrix
0
255
Member Avatar for the_kitoper

I am developing a program's GUI and have been using GTK heavily. However, I have run into some trouble... I need to use gtk_signal_disconnect yet I have been having trouble finding a webpage that describes handler_id. Please help.

Member Avatar for nezachem
0
60
Member Avatar for ana_1234

Hey, I have a file that I am working with that I have pass into my program through command line arguments. I don't want to touch the file, just want to store a temp of the file then after fixing the temp place it back in the original. After running …

Member Avatar for WaltP
0
350
Member Avatar for apanimesh061

[CODE] #include <conio.h> #include <iostream> #include <cstring> #include <ctype.h> using namespace System; using namespace System::String; enum CardType{ MasterCard, BankCard, Visa, AmericanExpress, Discover, DinersClub, JCB }; bool Validate(CardType cardType, String cardNumber){ int number[16], len=0; for(int i=0; i<strlen(cardNumber); ++i){ cardNumber[i] = atoi(cardNumber[i]); if(isdigit(cardNumber[i])){ if(len == 16) return false; number[len++] = cardNumber[i]; } …

Member Avatar for teo236
0
1K
Member Avatar for bandrei2408

Hello ! I need your help to calculate the complexity of a program. I need this for my exam and i can't understand how it is calculated. I've tried searching for solutions on google and reading about it but i still can't get it. Maybe if someone can calculate it …

Member Avatar for bandrei2408
0
142
Member Avatar for vergil1983

Hi, i new here.... I'm making a program which can calculate the below expansion of Ln)(1 + x) = x/1 - x^2/2 + x^3/3 - x^4/4 + x^5/5 - x^6/6 Below is my syntax [CODE] #include <iostream.h> int main() { float num1; cout<<"Enter a number: "; cin>>num1; num1 = num1/1 …

Member Avatar for deliezer
0
3K
Member Avatar for K0ns3rv

A little program I made to try and remeber C++, first program I've written in C++ in about a year. Tested and working under windows 7 64 bit, run via command line. If you have any improvements or ideas please leave a comment. Cheers K0ns3rv

Member Avatar for mrnutty
1
321
Member Avatar for deliezer

Hello, I have a difficult memory error to find. I have narrowed it down to a small piece of code, tiny in fact, but the symptoms are baffling to me. I tried to find it with electric fence, but electric fence found nothing. The problem is complicated by my liberal …

Member Avatar for deliezer
0
89
Member Avatar for learningcpp

Hi All, I am facing issue again and would be great if you help me to understand this code: [CODE] #include <iostream> #include <ostream> using namespace std; class A{ int a; public: A(int a):a(a){ } A operator+(A &other){ A aaa(a+other.a); return aaa; } friend ostream& operator<<(ostream &stream, A &aa){ stream …

Member Avatar for learningcpp
0
160
Member Avatar for hutzy

Can someone help me i try c++ text with color and it is blinking now i want the text is moving whatever right to left, left to right. I have no idea plsss i begging someone plss help me exmple plss or teach me!!

Member Avatar for Narue
0
457
Member Avatar for Celtrix

I am having trouble running the lua interpreter at the same time im running sdl and am also having trouble with processing events in sdl while lua is embedded basically in some pseudo code this is what it looks like so far [CODE] #include <lua.hpp> #include <SDL/SDL.h> #include "user.hpp" int …

Member Avatar for Celtrix
0
347
Member Avatar for roidw

Hi, I'm a beginner, and I'm looking for the simplest way to get the source of a webpage into a string under Win. Also, I'm using Dev-Cpp, and I noticed that many of you don't like it, what would you recommend instead?

Member Avatar for VernonDozier
0
85
Member Avatar for WaltP

For years when people post that they are using Turbo-C/C++ they always get a heated response saying basically "[I]why are you using that piece of sh*t? Use Dev-C++ instead.[/I]" Dev-C++ was being recommended because it's newer, it followed the standard better, it's free, etc. A couple years ago, though, it …

Member Avatar for pseudorandom21
0
1K
Member Avatar for treger69

Hi my name is Chris and I am currently enrolled in CMIS102 class. I am really banging my head :@(on multiple occasions) with my latest assignment. I have read every forum, book, and troubleshooting guide there is but nothing out there that has helped me to find the result or …

Member Avatar for prvnkmr194
0
414
Member Avatar for learnersunakshi

[CODE]// Program Dictionary // Proogram that uses linked list to maintain a dictionary #include <iostream.h> #include <stdlib.h> #include <stdio.h> #include <conio.h> #include <string.h> #include <ctype.h> class dict { private : struct node { char data[20] ; char m[100] ; int mcount ; struct node * link ; } *dic[22] ; …

Member Avatar for Agni
0
1K
Member Avatar for sadsdw

Hi friends, I wrote a code to build a matrix with specific calculations. When I'm using 3000 elements works well ... But I did a test with 150.000 (150.000 x 150.000) and I had problems. " terminate called after throwing an instance of 'std::bad_alloc' " I'm copying the code part …

Member Avatar for sadsdw
0
2K
Member Avatar for v_janssens

I have a class Node and want to declare an initially unknown number of instances of this class at run-time. First the program determines the number of nodes (num_n) from the user and then I want to define num_n objects. I have crudely got around this by defining a maximum …

Member Avatar for alwaysLearning0
0
212
Member Avatar for lenzo

excuse me if this question has been asked before than i am sorry i couldn't find it. so i am ruining Ubuntu on my desktop computer and i have started c++ using code blocks i was wondering how do you make a GUI window for Linux or am i using …

Member Avatar for Celtrix
0
290
Member Avatar for CPT

I know that you can use assembly combined with C++(either inline or using modules written completely in assembly, linked with the rest of the program), and I was curious how does a program written in different programming languages(eg Mozilla Firefox)work, and how it gets built.

Member Avatar for Celtrix
0
108
Member Avatar for sachinchandora

i have a error in c graphics "segment exceeds _TEXT 64K" i reduce some lines but i have no solution please help me as soon as possible i want to complete my program as soon as possible please help me some one

Member Avatar for Salem
0
1K
Member Avatar for ali jiger

Win32 based application (Using DirectShow and VC++), that uses the UVC driver (part of WDK) in the background for the tasks we require to implement.

0
65
Member Avatar for thecoolman5

hi, i am using DEV-C++ and i have two problems with this code: [CODE]#include<iostream> #include<string> #include<sstream> using namespace std; int main (char argc) { string n1; getline(cin,n1); int len; len = n1.length(); int len1 = -2; int len2 = -1; for(int t = len; t>0; t--) { len1 = len1 …

Member Avatar for thecoolman5
0
578
Member Avatar for Labdabeta

I have been away from internet connection for awhile. Anyways, I am still having library issues using VBOs. Now the only warning that I am getting is [ICODE]undefined reference to 'XXX@Y'[/ICODE] Where XXX is either CreateFont, SelectObject, ChoosePixelFormat, SetPixelFormat, GetObject, DeleteObject, or SwapBuffers and Y is a line number. What …

Member Avatar for Labdabeta
0
145
Member Avatar for tomtetlaw

I'm trying to understand how to change a windowed-window to a fullscreen-window at run time. What I do is use a DEVMODE structure with ChangeDisplaySettings when I want to make it fullscreen. I set the width and height to the width and height of the screen, which is fine. But …

Member Avatar for tomtetlaw
0
1K
Member Avatar for hadiza

please how can i write a complete c++ program that prints full name and registration number in two lines

Member Avatar for Narue
-3
113
Member Avatar for macla
Member Avatar for kuntakkhong

how to write a programme that read an integer between 0 and 9999 and add all the digits in the integer. for example, if an integer is 8235, the sum of entire digit is 18.

Member Avatar for Moschops
-1
45

The End.