49,761 Topics
| |
Hello everyone, I'm trying to compile the "Simple VRML" example, from the ARtoolkit library. The problem is that when i try to compile it, it keeps telling me: [CODE]1>------ Build started: Project: UANLartoolkit, Configuration: Debug Win32 ------ 1>Linking... 1>LINK : fatal error LNK1104: cannot open file 'libjpeg.lib'[/CODE] Now, thats kind … | |
I have two questions relating to classes. I have run into a problem in using classes in multi-file programs. Here are three example files which illustrate the problem I am having and the errors I am getting. [B]file1.cpp[/B] [CODE=c++] //file1.cpp #include<iostream> #include"file3.h" using std::cout; using std::cin; namespace baz { extern … | |
if cin.get(str,256); executes, why it reads only 255 characters???? answer immediately please | |
[CODE] #include<iostream> #include<stdio.h> #include<conio.h> using namespace std; int main () { float nep,b,sum,temp,i,j,median; cout<<"Enter the number of Elements"; cin>>nep; double element [10]; int index; for (index=0;index<nep;index++) { element[index]=0.0; } for (index=0;index<nep;index++) { cin>>element[1]; sum=element[1]+element[2]; element[1]=element[2]; element[2]=sum; } b=sum/nep; cout<<"Mean:"<<b<<endl; for(i=0;i<nep;i++) for(j=i+1;j<nep;j++) { if (element[3]>element[4]) { temp=element[4]; element[3]=element[4]; element[4]=temp; } } … | |
#include "StdAfx.h" #include <iostream> using namespace std; int main(); { cout << "7 + 3 = " << 7 + 3 << end1; cout << "7 - 3 = " << 7 - 3 << end1; cout << "7 * 3 = " << 7 * 3 << end1; return … | |
I have a quick question about posting. I am retaking over my final C++ class and still have the programs from the class. Even thought the class is a month away I am planning on working on them early. Would there be anything wrong with posting about each piece of … | |
Hello everybody! I wrote the following classes: OilStation: [CODE] class OilStation : public Date{ protected: int code; char *Address; float Amount[K]; public: ... }; [/CODE] and Price: [CODE] class Price : public OilStation { public: Price(){} void changeAmount(); ... }; [/CODE] In changeAmount function i try to change the elements … | |
Ok so ive been writing code for a web server to return requested files, It works well for html and txt files but when an image is requested all i recieve is the url of the file... In firefox in conqueror i dont get anything. All i do is read … | |
Can any1 help me too debugg this program..........pls........... if possible post d debugged program here itself or mail it to me <<>> thank u in advance :) the following is a program of edge detection in an image..........i m gettin errors in both dev C++ and Code blocks [code] #include<iostream.h> … | |
hi every one,i am a new guy for Mfc Socket programming . tell me ,what are the best books available for Mfc socket programming (Csocket). | |
Hi, I'm very interested in neuroimaging research and I'm applying to cognitive neuroscience PhD programs for next fall. I'm hoping to increase my proficiency in several computer programming languages because I know how important they are for neuroimaging research. Specifically, I'd like to learn C++ for MATLAB. It might be … | |
Hello I'm trying to pass a key array to a function in another class and its not working. Can anyone explain to me essentially what the key array is? Is it an array of char? Well anyways here is my code I'm getting errors please help. Thanks HERE IS MY … | |
Hello I am developing my first game in Allegro. Till now i found it easy to use. But now i read that for running a game allegro.dll is required on computer. Tell me if it is correct. Also many people say that SFML is better than Allegro, since the latter … | |
When I try to build a C++ project I get the error message in the title line. I am trying to help my son move his development from a unix cluster to his laptop. He is running Windows XP Pro and has installed the Eclipse IDE for C/C++ Developers. The … | |
Hello.... I am running a C++ program that takes an N array and reads a from a file. One requirement of this project is that it returns an elapsed time of each function so the function efficiency can be calculated based upon an input. I am attempting to implement the … | |
Hi All We all have read a lot about utility of copy constructor. I have a simple question .Consider the code below. Is it ok to directly copy one object's content onto other ? [CODE] Class A { ...... }; main () { A * obj_1=new A(); // Next the … | |
[CODE] #include "includes.h" int main() { SYSTEMTIME st; GetSystemTime(&st); ofstream syslog; //st.wDay= 30 syslog.open("today"st.wDay".txt"); syslog.close(); system("Pause"); } [/CODE] bt idk how to make it this line is completly wrong syslog.open("today"st.wDay".txt"); can anyone help me :) | |
I'm trying to convert LPWSTR to LPSTR withi this: [CODE] LPWSTR *argvw; int argc; argvw = CommandLineToArgvW(GetCommandLineW(), &argc); LPSTR argv = new CHAR[argvw->size()+1]; WideCharToMultiByte(CP_ACP, 0, argvw->c_str(), -1, argv, (int)argvw->size()+1, 0, 0); [/CODE] but I'm getting this: [CODE] main.cpp:14: error: request for member 'size' in '* argvw', which is of non-clas … | |
i am just trying basic C++ GUI and i ran this code from a tutorial site. [CODE] #include <windows.h> int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrev, LPSTR pszCmdLine, int iCmdShow) { MessageBox(NULL, "Hello World", "Testing", 0); return 0; } [/CODE] when i run it, it executes and makes a animation of … | |
Hi, I need to store each path in a tree as a row in a two dimensional array of size #of paths x N. I couldn't find the appropriate indexing scheme for the array. Any ideas would be appreciated. Thanks, | |
Anyone here can help me with Boyer Moore algorithm? Im study lots of code and example for couples of hour already and yet i cant figure it out how does the Boyer Moore algorithm works.. It really too complex for me .Can anyone give me a sample code or perhaps … | |
I'm new to C++ programing. the compiler can't find "atlstr.h" to include. I searched alot for this file but I couldn't find. Please, and body knows how to find it , tell me ASAP. | |
Hey I have problem... If i save playlist with 1 item then it work but if i have more then it bug. i can start debugging. [CODE]XmlTextWriter ^textWriter = gcnew XmlTextWriter(dig->FileName, nullptr); textWriter->WriteStartDocument(); for(int i=0; i < listBox1->Items->Count; i++){ textWriter->WriteStartElement("track"+ i); textWriter->WriteStartElement("url", ""); textWriter->WriteString(listBox1->Items[i]->ToString()); textWriter->WriteEndElement(); textWriter->WriteStartElement("name", ""); textWriter->WriteString(listBox2->Items[i]->ToString()); textWriter->WriteEndElement(); textWriter->WriteStartElement("start"); … | |
Can anyone help me solve this problem? pass by reference/value and file i/o should be used.. Write a C++ program which will read in a list of numbers, find the average of all numbers, the average of thepositive and negative numbers, and the largest element. Your program should contain at … | |
hello everyone i am trying to make a list that contains name with following option add till name write out names in the list remove name from the list sort the list look efter a name from the list save the list to a file please i will appreciate if … | |
Hi, I have a text file with characters. I must able to read the length of characters in the file by every line and count the frequency of each characters for each line. I have tried on writing this program but this does not work. Can anyone help me on … | |
Hey guys, This is my first official post on DaniWeb :) I am new at programming in C++ using visual studios, and right now I am fooling around with storing user input into Arrays. I am having a problem with my code, using an array size of 3 to store … | |
Hi there i wanna make a query like this [CODE]SELECT * FROM accounts[/CODE] accounts table has 3 columns ID Name Password so i wanna get every column value in variable like char name= column[name]; so i can cout << name ; is there away to do it? | |
I cannot copy 2d array. There are no errors in my error list. What is wrong with my code? The problem might be located in create(). Thanks in advance. Here is my code. [CODE]int **map void randomize(int numberToSelect,int range, int *list){ int* remainingNumbers = new int[range]; int* chosenNumbers = new … | |
hey. How to load and save to XML. xml like: [CODE][track1] name= url= starttime= [/track1] [track2].... [/CODE] and how to load only name to listbox without all link. |
The End.