49,766 Topics

Member Avatar for
Member Avatar for bubbleT

Hi I'm new to XML file. I have the following format XML file and I only need to read the value for data name = "A2" in VC++. How to read the value using the XML DOM methods without looping all the nodes? My xml file is as follows: [QUOTE] …

Member Avatar for bubbleT
0
808
Member Avatar for TheFearful

Hey, I am working on a project and I want to know how to return a class object that is a Character Array. I am having trouble with it and can't find out any way to do this. Thank you for taking the time to help (:

Member Avatar for triumphost
0
229
Member Avatar for pseudorandom21

Can I use a DLL embedded in an executable (as a resource) without writing it to the disk? (Windows)

Member Avatar for pseudorandom21
0
1K
Member Avatar for pseudorandom21

I'm attempting to transfer some OpenCV images over the network, I've been trying to put them into a format I can easily encrypt and transfer, but I'm almost certain it's not going to work properly. Essentially the IplImage is a structure but it has a pointer that points to some …

Member Avatar for pseudorandom21
0
770
Member Avatar for coolbits

I want to create a struct array and get the max number of books written by particular author...The problem is that i can't get the number. I am not finished up yet with the code,but i don't know why i am not getting anything when calling the Max function.Please advise! …

Member Avatar for coolbits
0
146
Member Avatar for ClausL

Hi guys, Found this thread while searching to solve my problem ... anyone an idea why this snipet leaks? [CODE]void testMemoryLeak() { HINTERNET hSession = WinHttpOpen(NULL, WINHTTP_ACCESS_TYPE_NO_PROXY, WINHTTP_NO_PROXY_NAME, WINHTTP_NO_PROXY_BYPASS, 0); WinHttpCloseHandle(hSession); } [/CODE] a 20'000 loop brings memory up to 19MB VS2008 on Win7/64 building a console application Win32 Cheers …

Member Avatar for Ancient Dragon
-1
77
Member Avatar for xtinab

For a project I'm doing for class I have to make a virtual method in a class. A subclass will inherit the virtual method and instantiate it in a separate .cpp file. The problem I'm having is that I need the class that has the virtual method to instantiate its …

Member Avatar for Ancient Dragon
0
222
Member Avatar for rigoalhn

I need help with this assignment. I got some done for the input validation but im having problems to understand classes. Ill provide the code below. Design a class called Date that has integer data members to store month, day, and year. The class should have a three-parameter default constructor …

Member Avatar for Ancient Dragon
0
3K
Member Avatar for fredz0003

[CODE]int initScoreX; int initScoreO; int oldScoreX; int oldScoreO; int newScoreX; int newScoreO; int ScoreBoard(char Player) { int ScoreBoardPositions[99]; //counting all the way to 99 //let's say X won that round, so I add 1 to the old score oldScoreX + 1 = newScore; //let's say the new score is 16 …

Member Avatar for WaltP
0
114
Member Avatar for mohy93

i need help with this program, i need to give the user 20 chances to guess, and they should be asked if they want to playagain.(by playing again i mean generating a new number with 20 new chances) after playing for how many times i should count the number of …

Member Avatar for WaltP
0
215
Member Avatar for pattmorter

So I was doing some code for input validation on my homework program and i have the correct code to make sure a number entered it correct but I thought, what if they enter a letter. We aren't required to make sure that the user entered a number but how …

Member Avatar for WaltP
0
179
Member Avatar for a.muqeet khan

hello guys ! i have created a program just to understand how to return a value from using a recursive program what it does it thati have have two variable i.e first and last the value of first is zero and last is 10 not i want the function to …

Member Avatar for Tumlee
0
165
Member Avatar for CodeNinjaMike

Ok, I've been trying to wrap my head around this code for the longest time today, and I've tried to look up multiple web pages on how to solve my issue in a different way, but it's no use. There's something that Im not seeing that separates a regular array, …

Member Avatar for mrnutty
0
4K
Member Avatar for jonnyboy12

Hello i am finishing up a pop3 program and now am looking for a way to view the html i receive form the pop3 server that comes along with some messages. People have told me to use a web browser but that seem over kill. Could i dissect a web …

Member Avatar for thines01
0
172
Member Avatar for kongkornitz

Hi, need help with an assignment. Here is the problem and the code the I came up with. It displays the start and the end but it does not display the numbers in between. Thanks in advance. ;) [CODE]//create a C++ program that will accept 2 numbers: (Start Number and …

Member Avatar for thines01
0
149
Member Avatar for dellat

I have a question on a very basic operation of modulo operator. [B]Why does 1 % 9 produce 1?[/B] If 10 % 9 then remainder is 1. I am very poor in math but have had to use modulo operator many times before but always become confused and couldn't understand …

Member Avatar for dellat
0
119
Member Avatar for greatman05

So, I'm a bit confused with how inheritance works in relation to variables. Let's say that I had the following class: class Test { private: int var1; float var2; public: void getInfo(int,float); void setStuff(int,float); }; Now, let's suppose that I wanted to derive a class from that base class; I …

Member Avatar for Ancient Dragon
0
208
Member Avatar for gunnerone

Hi I am working on Linux and I am trying to create a GUI app to go with my executable I have made. For some reason it unexpectedly ends. There is no error message, it just says in the Qt console window it unexpectedly ended with exit code 0. Can …

Member Avatar for gerard4143
0
197
Member Avatar for user543820

Hello! I am trying to implement search algorithms in a 2D grid. The problem I am facing is that let's say that I make a 2D grid in c++ through some array and also block some cells. Now how will I convert this grid into a binary tree to run …

Member Avatar for L7Sqr
0
123
Member Avatar for a.muqeet khan

hello guys ! i have created a program just to understand how to return a value from using a recursive program what it does it thati have have two variable i.e first and last the value of first is zero and last is 10 not i want the function to …

Member Avatar for a.muqeet khan
0
168
Member Avatar for Tygawr

Hello everyone, I've attempted to use ifstream to open and read a 20GB file but failed to do so (it takes a very very very long period of time...). So, I need find a fast way to open and read a 20GB .txt file in C++. Thank you!

Member Avatar for Tygawr
0
255
Member Avatar for lanario

I'm lost based on the code provided, how to reduce a fraction down. I've looked on the internet and yes most are using global variables; I however, can not for my class. It must be within the function. And there needs to be two calls outside of each of the …

Member Avatar for LUDACHRl5
0
603
Member Avatar for Tygawr

Hello everyone, I am having a hard time reading and writing a UTF-8 file in visual c++ 2010. [CODE] void ReadUTF8File() { ifstream UTF8File("C:\\DaniWeb\\Desktop\\UTF8File.txt"); /* UTF8File.txt: ☺☻♥♦♣♠•◘○ */ string UTF8FileStr; if(UTF8File.is_open()) { while(!UTF8File.eof()) { UTF8File >> UTF8FileStr; cout << UTF8FileStr << endl; /* cout: ∩╗┐Γÿ║Γÿ╗ΓÖÑΓÖªΓÖúΓÖáΓÇóΓùÿΓùï */ } } UTF8File.close(); } …

Member Avatar for thines01
0
7K
Member Avatar for FraidaL

I'm receiving this error when I'm trying to run my program: Program received signal: “EXC_BAD_ACCESS”. Does anyone know what this means?

Member Avatar for thines01
0
249
Member Avatar for Jorox03

I'm doing an assignment for school which is to simulate the grep command in C++. We are to take in a word to search, an input file to search through, and output file to output the results. The only text that should be in the output file is the contents …

Member Avatar for WaltP
0
213
Member Avatar for rbran74

when using setprecision(2) when i try to display the number .90 it olny outputs .9 is there anyway to make it so that it display .90 instead of .9.

Member Avatar for pattmorter
0
135
Member Avatar for FraidaL

I'm writing this program to calculate the best fit line. It's not finished. I'm doing it step to step to make sure it runs so I don't get lots of errors and totally freak out at the end. Right now it runs fine, but something is really off with the …

Member Avatar for FraidaL
0
237
Member Avatar for triumphost

I'm trying to help someone with homework.. So you do not have to give me direct answers if you don't want to.. it is not my homework. [CODE] class Types { //No default constructor.. Types(int Param1, int Param2); }; class Objects { public: Types* Original; Objects(); ~Objects(); }; //The problem …

Member Avatar for triumphost
0
150
Member Avatar for Prisms

I am trying to compare a string from my text file to a user input i was wondering how I would do this I have tried the == operator but that seems to be getting me no where. I am currently trying to use the .compare() but it doesn't seem …

Member Avatar for Prisms
0
213
Member Avatar for Tygawr

OOPS! SORRY WRONG SECTION, I WANTED TO POST IN THE C++ SNIPPETS.. This piece of code will search for a string in a text file and write the results into another file along with the line number. [CODE] void IOSearchString() { string SearchString, InputFilePath, OutputFilePath, InputFileLine; cout << "Welcome!" << …

0
80

The End.