49,756 Topics
![]() | |
My problem: I made 1- A new MFC application (exe) (c++ .net 2005), dialog based. 2- Get from the toolbox a control which is "Picture Control". 3- Set the type of the control to Bitmap in the property window of the control. 4- Add new bitmap to the resources at … | |
[ICODE]//Deck Class #include<iostream> #include<stdlib.h> using namespace std; class Deck{ int Cards[51]; public: Deck(); void Display(); void Shuffle(); }; Deck::Deck(){ for(int n = 0; n < 52; n++){ Cards[n]=n; } } void Deck::Display(){ for(int n = 0; n < 52; n++){ cout << n+1 << ". " << Cards[rand()%51] <<endl; }} … | |
Hi, I have a problem because : this is my code [code] #include <iostream> #include <windows.h> // Sleep() #include <mmsystem.h> // mciSendString() using namespace std; // std::cout, std::cin int main() { mciSendString("open CDAudio", NULL, 0, NULL); Beep(440,1000); cout << "Opening CD-ROM door ..." << endl; mciSendString("set CDAudio door open", NULL, … | |
Hi, is there a socket library [B]besides WINSOCK[/B] that I can use with Dev-C++. I don't have a <sys\socket.h> include. Is there a devpak that I can get, or am I doomed to WINSOCK? | |
Hi, Im trying to write to specific points in a file, but the write() erases everything in the document..heres what im doing: the file: [CODE] mode 0 ; level 0 ; menu 1 ; [/CODE] the code: [CODE=C++] ofstream data_w_fil; data_w_fil.open("data.gsp"); data_w_fil.seekp(7); data_w_fil.write(mode, 1); data_w_fil.seekp(18); data_w_fil.write(level,1); data_w_fil.seekp(28); data_w_fil.write(menu, 1); [/CODE] … | |
Hello guys, I'm making a C++ project on periodic table.In that,i want to search for elements on the basis of their names in such a way that if i give an alphabet or more than 1 alphabets as the search value then all the elements starting from that letter should … | |
There are many new standards in C++ 2009 , but I don't know where the document or website about this is! Please help!!! | |
hi! i just have a brief question I couldnt find the answer for on the web. whats the access code for the mouse scroll click? as an example, if i would like to write an [B]IF[/B] thats cecking if the user has pressed the sroll wheel on his mouse, how … | |
Hi :) I have a problem. I have a class, called Sequence, which is a template. One of it's member variables is a vector or elements of type T. I would like to create a constructor which takes as it's argument an array of elements of type T and feeds … | |
Hi, I'm using WinSock, and am making a function to receive data. How can I know when I have reached the end of the data that I'm receiving. Like, if I send "GET /" to [url]www.google.com[/url] on port 80, I should receive the HTML of the index page. But in … | |
Hello all, I am just practicing on class. From what I have learned thus far (from the internet) I made a simple program that resembles picking a deck of cards. But my problem is that although it works. I cannot get it to generate different cards for each object. To … | |
deleting first element of an array.... deleting last element of an array... deleting middle element of an array... inserting first element of an array.... inserting last element of an array... inserting middle element of an array... searching the 2nd highest positive even integer thanks i need it... thanks | |
I have an array of doubles that is output to a file and was wondering if there is a way to output white spaces where the value is 0 without replacing the 0's another value contains? example... number1 = 100 would still read number1 = 100, but number2 = 0, … | |
Hi Everybody, My question is half about programming, half about the video structures. I hope you can help me. 1)I want to write a program to open a .mpg file as a binary file(can any file be opend as binary file?), then packetize it (every 188 bytes should be a … | |
i want to make a program in c++ , such that if the right arrow key is pressed 1 is displayed else if left arrow key is pressed 0 is displayed. please give me the code to do so and explain too. | |
Hi there, could anybody please do me a big favour and help me with the source code for: [img]http://i39.tinypic.com/2eof7lv.jpg[/img] Thanks | |
Hello again everyone, Having a really annoying problem using pointers and arrays at the moment, i'm trying to store a 4x4 matrix as a an array of 16 floats. so i declare my array like so [code=C++] float array1[] = {1.0f,0.0f,0.0f,0.0f, 0.0f,1.0f,0.0f,0.0f, 0.0f,0.0f,1.0f,0.0f, 50.0f,0.0f,0.0f,1.0f}; [/code] i then pass this into … | |
I have been working on a program which requires to retrieve the names of all the current windows on the desktop. I can retrieve the name using the Windows API function GetWindowText(). But i require a function to retrieve the handles to all the windows. I want to know which … | |
Hey guys. I am making a simple console canender program for an exercise from a book, and it is going ok so far but I am having trouble with the spacing of it. I have made a simple function that creates on day block like a normal calender would have, … | |
I am trying to overload << for a class complex. The code is: INTERFACE: [code=cplusplus] class complex { friend ostream& operator<<(ostream& output, const complex& V); private: double REAL; double IMG; public: complex(); ~complex(); }; [/code] IMPLEMENTATION of <<: [code=cplusplus] ostream& operator<<(ostream& output, const complex& V) { output<<"("<<V.REAL<< "," << V.IMG<<")"; … | |
I was trying to do the practice problems but don't understand what the first beginner or first intermediate problem is asking me to do Write a program which finds the factorial of a number entered by the user. (check for all conditions) (Beginner). Create a simple Palindrome checker program. The … | |
I have the ambition to make a List, Global so it can be reached within other Threads. When compiling the code with the declared list like this the compiler says: [I]syntax error : missing ';' before '<'[/I] Should I declare the List in any other way than this ? (The … | |
Hello, I have recently started learning how to write games in DirectX 9 and I have a few questions. The first is about backwards compatibility. Is it correct to assume that if someone has DirectX 10 installed that they can play DirectX 9 stuff without downloading DirectX 9? Also, I … | |
I have put about 30 trasparent buttons on a Form wich meens that all these buttons are invisible. When I open this Form, you will see all these trasparent/ invisible buttoncontrols "flicker" in a white color. This flickering process takes about 2 seconds until the Form is 'ready'. What does … | |
I want to write a 3D virtual environment in c++ that can display videos on sides of a cube (using openGL is preferable). Also it has multi client and connect to the server that has a database of videos. the program should work online and can be displayed in web … | |
Hello, I'm trying to solve an assignment that I have, but I don't want to get into the details of the assignment and confuse everyone. But, the basic idea is that I have to read a file, containing a list of team names and information about matches, and then I'd … | |
Hi all. I'm having a difficult time working with visual studio 6.0. I have a project which i'm editing, and i need to add a combobox to a form. The problem is i've added items to the combobox throught it's properties, and yet when i run the program, only the … | |
Hi i am trying to understand manipulators. Can someone explain what is happening here [code=C++] for (int i = 0; i < n; i++) { cout << setiosflags(ios::left) << setw(15) << item[i] << setw(8) << setprecision(0) << code[i] << setiosflags(ios::right) << setw(8) << setprecision(2) << setiosflags(ios::fixed | ios::showpoint) << cost[i] … | |
Hi, I have given only some part of the code related to my problem. I have problem while compliation. I have the problem in the constructor of the class RMstore. i Get the following compilation error rmremote_server.cpp: In function `int main()': rmremote_server.cpp:196: error: no matching function for call to `RMStore::RMStore(std::string)' … | |
What I want to do is make a grading system. There is a vector for schools and classes and students, all of these which have their own class, derived from a class called system. [CODE]class System{ School * p; //School Pointer vector<School>sSort; public: //Splash Screen Function void Splash(); }; /*-School … |
The End.