49,761 Topics
| |
Hi Got a comboBox on a form where the user can add url favorites, When closing form using the following code. [CODE] // Create the XmlDocument. XmlDocument^ doc = gcnew XmlDocument; doc->LoadXml( "<item><name>Favorites</name></item>" ); for(int i = 0; i < this->ComboBoxBM->Items->Count; i++) { // Add a url. XmlElement^ newElem = … | |
im trying to learn pointer n the &(no idea the specific name for it); so my question is.. im passing the memory address of P to changePTR, why p is not taken the address of o(lets assume o is dynamic allocated), or even i want to change p to NULL. … | |
So, I've been learning DirectX10 and have had alot of questions... I'm sure i've frustrated about all the people that are willing to help me with my DirectX problems (Sorry about that) but now i have a new problem. I have some source code that i downloaded from a site … | |
Hello. I'm currently making a program that deals with a priorityQueue and inheritence/polymorphism. Student -> undergrad -> coop_student or student -> grad Now, the queue takes in the data and just puts it in a linked list and gives it a priority. That way, there are 3 queues and we … | |
pls help me. i have got a school project to make a program that generates a shopping bill and shows the present stock at end of bill. also 1.the user inputs only the quantity and product code(thats where i am facing problem to feed the product codes in my program … | |
hi, im working on josepus problem but this programe is not working well it is working in unlimited loop any one can point out the mistakes????????? #include<iostream> using namespace std; class node { private: int object; node *nextnode; public: int get(){return object;}; void set(int object){this->object=object;}; node *getnext(){return nextnode;}; void setnext(node … | |
Hello, So I have a .txt file which is kind of built like: N 1234554321 Joe Jones Y 1234555432 Sarah Clark Y 1234321231 Kirah Williams N 1234212321 John Johnston The output, line by line, as the txt file is, and it works and all, I output "Y" or "N" I … | |
Hello, I am making a program where you are entering 2 numbers which should be product AND sum of other 2 numbers. The program then outputs what are the other 2 numbers. For example if I enter sum 13 and product 22 the program will output 2 and 11. But … | |
Hi! I need some guidance on this project. I wrote most of it, but i would like to improve my code by implementing more functions, and im open to hear suggestions on my code. My main concern is, every time the user picks one of the drinks it should subtract … | |
[code]// header moduleinjector - header for class moduleinjector itself // as well as "core" moduleinjector-related functionality namespace Injection { class moduleinjector {...}; ... // ... = core related functionality e.g. non member functions almost all clients need ... } [/code] when you construct a moduleinjectior object you must pass in … | |
Ok.. this is actually regarding game hacking, but I wish to gain knowledge from this procedure. Here is the scenario. The game is a server based multiplayer role playing game in basic 2d form. What I want to be able to do is simply manipulate what I see. For example.. … | |
Hi, I am writing an FPS game in C++ using OpenGL. I am trying to write the crouch system but I want to make the crouch more smooth. At the moment you press the crouch key the character immediatly moves down. Here is the code: Crouch Down: [CODE] entity[0].crouching = … | |
i am new to programing, i installed borland 5.5.1 c++ compiler so i practice my self.But i got some problems trying to compile, i dont know if the problem is from the i installed the compiler or something else. Below are the program i wrote and their compilation error. program … | |
Hello, I've finally come to a point when I want to send my program over to some people to test, however, I've run into problems on that. This is my first time writing a program in managed code(C++\CLR), and so far, all I had to do was pack the redistributional … | |
Help plz i am very confused :( how do i write a program that can input θstart, θstop, Npoints fill θ with values compute f(θ)=Asin(Bθ +C) + ...Dcos(Eθ +F) where A,B,C,D,E,F are variables | |
Hi there, I have a really quick question about a shuffling and dealing cards program I found in a book. here's main: [CODE]// Fig. 8.27: fig08_27.cpp // Card shuffling and dealing program. #include "DeckOfCards.h" // DeckOfCards class definition int main() { DeckOfCards deckOfCards; // create DeckOfCards object deckOfCards.shuffle(); // shuffle … | |
How to make a looping statement on c++ that will give an output like this? ___________@ __________@@@ _________@@@@@ ________@@@@@@ _______@@@@@@@@ ______@@@@@@@@@@ _______@@@@@@@@ ________@@@@@@ _________@@@@@ __________@@@ ___________@ (underscore represent space) | |
can you help me to solve an assignment in data structure using C++ ? | |
[COLOR="Green"][I]CAN YOU HELP ME TO SOLVE THIS Assignment.... PLEASE....[/I][/COLOR] [COLOR="red"][B][U]THIS IS THE QUESTION : [/U][/B][/COLOR]Implement the linkedPriorityQueue class as defined below. Note the following: ï‚· Each node in linkedPriorityQueue represents a customer. A customer can be regular or with a high priority. High-priority customers have their high_priority variable set to … | |
Hi, I am a little bit troubled. I want to call a function in a separate file on a windows form. Here is my header file: [CODE]private: System::Void button1_Click(System::Object^ sender, System::EventArgs^ e) { String ^OriginalText; String ^ConvertedText; OriginalText = this->textBox1->Text; ConvertedText = ParseBBCode(OriginalText); this->textBox2->Text = ConvertedText; }[/CODE] This means that … | |
#include <iostream> #include <fstream> #include <string> using namespace std; int main () { float calculateAverage(int[]); char Grade(float); char line[100]; int marks[100]; ifstream input; ofstream output; clrscr(); input.open("k:\\input.txt"); output.open("k:\\OUTPUT.txt"); if(!output) cout<<"Output file error"; if (input) { while (!input.eof() ) { input>>line; cout << line <<endl; output<<line; for(int i=1;i<=5;i++) { int num; … | |
right now my program asks for 5 candidates but i want to make the user input as many candidates as they want to. how would i go about doing that?? #include <iomanip> #include <string> using namespace std; int sumVotes(int list[], int size); int winnerIndex(int list[], int size); int main() { … | |
i have a prob wit this code...it says variable letter is being used without being initialized...can anione tell me how n where should i initialize it...plz...m desperately in need of help...i m blank...m jst a beginner in c++... the c++ code is... #include <iostream> #include <iomanip> #include <fstream> #include <string> … | |
Hello, I am a university student and I have very few courses this term so I have a lot of free time. In this term I want to improve myself and gain experience on C++ with algorithms and data structures. But I don't know how to do that... I have … | |
just have those questions about those code sinppets from the C++ GUI Programming with Qt 4 book: GoToCellDialog::GoToCellDialog(QWidget *parent):QDialog(parent) Does that mean we are inheriting QDialog(parent)? Or, what exactly does this mean? setupUi(this); Here, this code snippet is part of the gotocelldialog.cpp file, which is the implementation of gotocelldialog.h header … | |
Hi I am trying to convert the outbuff from WinHttpQueryHeaders to string but its not working properly... my code [CODE] if( GetLastError( ) == ERROR_INSUFFICIENT_BUFFER ) { lpOutBuffer = new WCHAR[dwSize/sizeof(WCHAR)]; // Now, use WinHttpQueryHeaders to retrieve the header. bResults = WinHttpQueryHeaders( hRequest, WINHTTP_QUERY_RAW_HEADERS_CRLF, WINHTTP_HEADER_NAME_BY_INDEX, lpOutBuffer, &dwSize, WINHTTP_NO_HEADER_INDEX); } } … | |
I'm trying to learn how to sort arrays. I tried to learn select sort, but I couldn't code it right... so I tried the easiest, bubble sorting and kind of got the hang of it! But with a few problems and questions. I'm trying to print an array with random … | |
hi.. everyone.. i wanted to ask can i actually combine c basic code in the c++ coding? | |
So here is my problem, my friend and I are writing a simple project for a electrical eng. teacher, who really doesn't know too much about programming c++. We were assigned to make a successive approximation ADC [URL="http://en.wikipedia.org/wiki/Successive_approximation_ADC"]Look here[/URL] in any coding language possible. I would have liked to make … | |
Hey everyone, I have to manipulate two functions RECURSIVELY, strlen and strcpy. I was able to code the strlen: [CODE]int length(char* str){ if(str == NULL){ return 0; }else{ return length(str, 0); } } int length(char* str, int l){ int len=0; if(str[l]){ len = length(str,l+1); } else { return l; } … |
The End.