51,592 Topics

Member Avatar for
Member Avatar for xiikryssiix

okay, i usually create beg programs and they often compile. for some reason, this one is not compiling at all. i cant seem to figure out whats wrong. my objective is to prompt user to open a file named "data.txt" have HELLO WORLD printed in a scrambled version to a …

Member Avatar for iamthwee
0
206
Member Avatar for VIkhers

dear sir... i got a confusing of this... [code]ifstream is; Char c, temp_isi_file[100]; int i; is.open ("b.a"); memset(temp_isi_file,'\0',100); while (is.good()) // loop while extraction from file is possible { c = is.get(); if (is.good()) if (c==',') { //cout << temp_isi_file << ":" ; [COLOR="Red"]textBox1->Text = Convert::ToString(temp_isi_file);[/COLOR] i=0; c='\0'; memset(temp_isi_file,'\0',100); } …

Member Avatar for VIkhers
0
212
Member Avatar for kokotsu

Hello, I was trying to create a Coalesced hash table by self teaching myself using various sources. I fixed most of the errors, but when i compile on either my visual C++ compiler or Dev -C++ both saids there is a undefine linker reference for the hash members in my …

Member Avatar for kvprajapati
0
109
Member Avatar for xiikryssiix

i am in beg c++ and my instructor is asking me to find "some other combination that also does not work! Your loop should prove something similar for values other than 10 cycles, steps of 0.1, and a sum of 1." i found 1 combination, which is in my program …

Member Avatar for xiikryssiix
1
112
Member Avatar for lotrsimp12345
Member Avatar for tazboy

Here is my function that reads in a list of integers and doubles the size of the array if there are too many inputs. The current size of the array is 10. [CODE=C++] int* read_list ( int *list, size_t *list_size_ptr, size_t *array_size ){ size_t index = 0; int *new_list; while …

Member Avatar for VernonDozier
0
98
Member Avatar for Nathan Campos

Hello, I'm new here in DaniWeb, and this is my first post, but i'm learning [I]C++[/I] and before this i was reading some tutorials in the internet of the [URL="http://www.adobe.com/br/products/air/"][I]Adobe AIR[/I][/URL] development, but if Adobe AIR is so much easy to learn and [I]C++[/I] is a very flexible and good …

0
71
Member Avatar for CppBuilder2006

console.cpp: [CODE="c++"] #include <iostream> #include <string> #include <vector> using namespace std; template <typename T> T #ifndef _DEBUG & #endif val(const T& x); class A { private: public: void f(); }; void A::f() { val(1);// deleting val solves the problem } int main() { new A; cin.get(); } [/CODE] general.cpp: [CODE="c++"] …

Member Avatar for Dave Sinkula
0
108
Member Avatar for monkey56657

Hello. I am quite new to c++ but am working on translating a prime generator I have made over from c#. I have everything working well but have found that c# can output to file faster than c++ (by around 10%). This is once the 'working out' is done. Here …

Member Avatar for monkey56657
0
280
Member Avatar for walter clark

I've been programming in C++ for 20 years and finally got the size of my mains down. I've been programming in C++/CLI for about 20 days, and I'm back to my old buggy-boo, uncontrolled file size. In this case it is the Form1.h file. It has about 20 controls using …

0
52
Member Avatar for seakayaker

Hi, I have developed a lot console applications in C++ using Visual Studio Express and I am curious how much effort it would be to wrap them with a ultra simple GUI? Do I have to purchase MFC or code hunded of pages in order to accomplish this in C++ …

Member Avatar for Stefano Mtangoo
0
152
Member Avatar for Cromarte888

Alright, I'm down to the nitty gritty absolute end of a fully functional hangman game. There is just one part where I am absolutely stuck. When you get a wrong guess, the game successfully draws the gallows. I have no issues with wrong guesses. It's the right guesses that has …

Member Avatar for Cromarte888
0
232
Member Avatar for Denxerator

Okay so, It's my first time on C++. They say you can use C++ to make games, so I want to learn about C++. (remember I'm a big newbie) So my question is, how does C++ work? Like if you put the C++ code in notepad, save it, open it, …

Member Avatar for tux4life
0
181
Member Avatar for born_to_code

i have to make a program to find the intersection of two strings, i have made program but its not working. any help will be appreciated.:) [code] #include <cstdlib> #include <iostream> using namespace std; void intersection(char *str1, char *str2) { int len1,len2,i=0,j,flag=0; char temp[30]; while(*str1!='\0') //outer loop for 1st string. …

Member Avatar for Tom Gunn
0
1K
Member Avatar for lotrsimp12345

ITS ALL THE WAY AT THE BOTTOM OF MY IMPLEMENTATION FILE. MAIN [code] #include <iostream> #include <fstream> #include "line_test.h" using namespace std; int main() { //open up file to be read string input; ifstream in; cout<<"enter file name which needs to be opened\n"; cin>>input; in.open(input.c_str()); while(!in) { in.close(); cout<<"the input …

Member Avatar for Dave Sinkula
0
108
Member Avatar for CppBuilder2006

please download the VC++ express 2008 project attached. it has linker errors. please help me solve the problem.

Member Avatar for CppBuilder2006
0
63
Member Avatar for BHUJI

Hi guys, I am in great trouble. I want a c++ project within 1 week!!!! But my teacher wants the topic name tomorrow ! pls help me give me some project ideas project should be simple&is in c++ language graphics are not allowed it can be management projects:sad:

Member Avatar for tux4life
0
270
Member Avatar for flair999

Hi ancient dragon. i need to extract specific words from 2 different point (directors and writers in a text file), like delimiters example of the text file below: i want [B]alex proyas[/B] to be extracted. words........ [B]DIRECTOR:[/B] alex proyas [B]Writers[/B]:...... this case is quite similar to the one above, but.... …

Member Avatar for Salem
0
90
Member Avatar for declain

Getting an access violation error when I get to the array sort code... Here's the code. Any thoughts? [code] // sort the shape arrays by area for(int i = 0; i < total - 1; i++) { for (int j = i; j < total; j++) //start at i { …

Member Avatar for bnekolny
0
87
Member Avatar for declain

I am working on an assignment that basically requires a class INT that operates similar to the int standard class... Below is my code. All seems to be working, with the exception of handling this line: INT x,y = 6; should assign 6 to x and y. Assigns only to …

Member Avatar for declain
0
121
Member Avatar for Denxerator

So on my last post, I asked about how to make C++ codes to work. This time I want to ask. How should I get started? Where should I get started to learn C++. Or what should I learn before I learn C++? Everything please XD. Oh and, I'm 12 …

Member Avatar for jencas
0
150
Member Avatar for dub4theworld

Well technically I don't know how to make it quit. I am very new to programming. I wrote my first program three weeks ago and I must say it is a wonderful mix of highs and lows, especially when your code compiles. Anyway, I have been trying to figure out …

Member Avatar for jencas
0
155
Member Avatar for gispe

hi all, i've written a program, n almost works, it just gives me this errors and dont know how to solve them :$ thanks for the help in advanced :D [code=cplusplus] 1>Compiling... 1>VersionFinalTpProg1.cpp 1>e:\esba\2cuat\programacion1\tpfinalaentregar\versionfinaltpprog1\versionfinaltpprog1\versionfinaltpprog1.cpp(199) : error C2676: binary '[' : 'art' does not define this operator or a conversion to …

Member Avatar for gispe
0
170
Member Avatar for gretty

Hi My program is rather simple, or I thought it would be rather simple :P My program reads a text file & saves each line of text into an array called buffer. [B]The problem is[/B]; each line of text is not in a separate array, the whole text file is …

Member Avatar for iamthwee
0
384
Member Avatar for massivefermion

Hi I'm trying to write a heap data structure but I have no idea how to do this.Could Someone help? thanks

Member Avatar for tux4life
0
202
Member Avatar for CppBuilder2006

hi I know C++ & I can write almost every console program with C++. How long will it take me to learn C#?

Member Avatar for Ramy Mahrous
0
146
Member Avatar for am_valentin

Hello guys, Is it possible to build an application for authenitcating on a domain, without actually providing the password? For example gesture recognition. I have read on msdn and they were talking about building a "custom authentification package" but this package calls MSV1_0 package afterwards. I am interested in a …

Member Avatar for am_valentin
0
145
Member Avatar for lotrsimp12345

why do i get undefined reference to error in my main with regards to isvalidname. It says undefined reference to... in my isvalidname i check if they enter in first name, char ws and then last name. Then i want to print out everything that i have deleted on that …

Member Avatar for lotrsimp12345
0
122
Member Avatar for BlinkOnly

Hello, Im programming an image reader and I need to print out a histogram that shows how many times a given pixel value is present in a image - actually it doesn't have to be the graph, just a table with two columns would be enough i have written a …

Member Avatar for Salem
0
121
Member Avatar for thEhAckEr

[code=splusplus]#include<iostream> #include<iomanip> using namespace std; int main() { int a[10][10],b[10][10],c[10][10],i,j,k,r1,r2,c1,c2; cout<<"Enter the order of I matrix\n"; cin>>r1>>c1; cout<<"Enter the order of II matrix\n"; cin>>r2>>c2; cout<<"Enter the "<<r1*c1<<" elements for I matrix \n"; for(i=0;i<r1;++i) for(j=0;j<c1;++j) cin>>a[i][j]; cout<<"Enter the "<<r2*c2<<" elements for II matrix \n"; for(i=0;i<r2;++i) for(j=0;j<c2;++j) cin>>b[i][j]; for(i=0;i<r1;++i) for(j=0;j<c2;++j) { c[i][j]=0; …

Member Avatar for thEhAckEr
0
92
Member Avatar for Stefano Mtangoo

I'm practing with Akrip32.dll for a time now and I can get the DLL version as DWORD. The Version is divided as HIWORD and LOWORD Can anyone help me interpret these Buzzwords? I have no Idea of what they are

Member Avatar for Stefano Mtangoo
0
444
Member Avatar for cougarclaws

Hi All, I Think I am close. I am trying to write a small user function that gives "roundCalc" to the main as a rounded number UP to the nearest 1000. (If 1011 should round up to 2000). I have "calcTotStat" reading in, and I thought I had it right, …

Member Avatar for cougarclaws
0
4K
Member Avatar for Orusaka

Okay, so I'm completly new to programming, and I've been using Sams Teach Yourself C++ in one hour a day over the last two days, admittingly taking in more than a days worth per day, though. This morning I decided I was bored of reading theory, and decided to get …

Member Avatar for VernonDozier
0
84
Member Avatar for Stefano Mtangoo

Hi All, I'm having trouble with my code. When I compile I get Undefined reference to class::method where by class and method are my class and method. I get my methods from akrip32.dll I,m at work so I have no source files, but I will attach them later when I …

Member Avatar for Stefano Mtangoo
0
228
Member Avatar for pltndragon

I have to drop the lowest score, and i can't include it in the calculation of the average. for input validation cant accept negative numbers for test score. #include <iostream> #include <iomanip> using namespace std; void arrSelectSort(float *, int); void showArrPtr(float *, int); void showAverage(float, int); int main() { float …

Member Avatar for NathanOliver
0
2K
Member Avatar for codedhands

Hello,i am writing an application which involves invoking multiple threads to pick data from a queue and then delete or pop the retrieved data.My codes work well for this purpose but then my application suddenly crashes with a dialog with the following error message: Debug assertion failed! Program:.... Expression:_BLOCK_TYPE_IS_VALID(pHead->nBlockUse) ------------------------------------------------------------------------------ …

Member Avatar for codedhands
0
214
Member Avatar for drt_t1gg3r

[CODE]struct boardType { int boardNumber[8][7][7]; int numberOfBoards; }; //note: int main() is assumed as standard "bloodshed DEV-C++" compiler boardType totalBoards; totalBoards.numberOfBoards = 8; totalBoards.boardNumber[0] = {{0,0,0,0,0,0,0}, {6,6,6,1,6,6,1}, {6,6,6,6,6,6,1}, {6,6,6,6,6,6,1}, {6,6,6,6,6,6,1}, {6,6,6,6,6,6,1}, {5,5,5,5,5,5,5}};[/CODE][QUOTE]expected primary-expression before '{' token expected ';' before '{' token[/QUOTE] Above shows the script I am trying to make …

Member Avatar for Salem
0
107
Member Avatar for debasishbasak

hi i am from bangladesh and read in ruet.i want to convert two dimensional array into one dimensional array.pls help me

Member Avatar for csurfer
0
125
Member Avatar for Furtano

hello, i defined t_wbrowser with the Webrowser Class. After i navigated to the Website i want to Copy the text the user selected on the Page. I have no idea how to do this, i googled and there was something with ActiveX but is there an easy way? [code] String^ …

0
71
Member Avatar for colmcy1

Hey all, need abit of help bringing a .exe window which has been previously open in my program.On a button click the program window should be brought to the front with "Alt+S" to be pressed. I am using MSVC 6 MFC and my code looks like: [ICODE]void CEvolveTraffic::OnButton() { // …

0
60
Member Avatar for bil050

struct A { virtual A* f() { return this; } }; struct B: virtual A { B* f() { return this; } }; The GNU compiler gives an error: sorry, unimplemented: adjusting pointers for covariant returns What is the problem?

0
48
Member Avatar for dzhugashvili

alright, so I recently obtained a reference implementation of MD5. I benchmarked it, and it ran about 30% faster than OpenSSL's MD5. The function call is as such: [CODE]fast_MD5(unsigned char *pData, int len, unsigned char *pDigest);[/CODE] it worked great for a simple MD5 hash cracker, but I had trouble tweaking …

Member Avatar for dzhugashvili
0
124
Member Avatar for VIkhers

Hello,, I'v had some problem,,, when i read a file,using visual C++ 2005. example: a.txt 111,222,333, 444,555,666 with this code : StreamReader^ din = File::OpenText(fileName); String^ str; int count = 0; while ((str = din->ReadLine()) != nullptr) { count++; Console::WriteLine("line {0}: {1}", count, str ); } How can I, convert …

Member Avatar for VIkhers
0
138
Member Avatar for wingers1290

Hi. I'm new to c# and have ran into a problem, I am using the following code to generate textboxes within a panel. [code] private void button1_Click(object sender, EventArgs e) { AddFields(); } private void AddFields() { if (textBoxIndex != 10) { TextBox field = new TextBox(); field.Name = "field" …

Member Avatar for wingers1290
0
230
Member Avatar for Azurea

Hey guys! I'm requesting constructive criticism on the code that I've written so that I might get a better idea of how to strengthen my code while keeping it short and sweet, or even just pointing out unnecessary things or things that I should have added. My assignment was: [quote]Write …

Member Avatar for siddhant3s
0
140
Member Avatar for kou yuuzhen

hello all, i'm a biology student currently taking programming in uni, and i have a homework question to solve. i have to write a programme to create and print a one-month calendar which can be used as month and year calendars as well. the programme should be able to; 1. …

Member Avatar for necrolin
0
164
Member Avatar for CoolGamer48

Hey, I download DarkGDK for Visual C++ 2008 Express (also downloading the correct version of the Direct X SDK). I just saved the SDK in some random directory, so when I try to execute the test code, i get an error telling me d3dx9.h can't be found. So, where do …

Member Avatar for Sepiantum
0
496
Member Avatar for kevintse

Well I am writing a program for Windows Mobile phone, I need to read text files in the program, the character sets (charset) of the files I am going to read are unknown, here I need to convert whatever text(Actually I probably only need to handle UTF-8, UTF-16 BE, GBK, …

Member Avatar for kevintse
0
314
Member Avatar for seakayaker

Hi, I wonder if you could recommend a book that talks about methods for optimization (error function minimization) in conjunction with C++? In particular I am interested in methods for numerically minimizing a multi variable error function, e.g. f(x,y,z, ...). My applications are such that I know that gradient methods …

Member Avatar for daviddoria
0
141
Member Avatar for colmcy1

Hey all, I am trying to check if a .exe file is open, if it is open bring it to foreground, if it is not open open .exe file and bring to foreground. The code I have written doesnt seem to recognise if the program is open or not as …

Member Avatar for colmcy1
0
2K

The End.