49,761 Topics

Member Avatar for
Member Avatar for gtschemer

Hi, I believe this is my first posting to DaniWeb, so thanks very much in advance for your time! I have been doing some searching and I am not sure of a definitive answer to the following problem. I am attempting to make a class that can store a set …

Member Avatar for Banfa
0
125
Member Avatar for Mike911

I need to prevent my window from going minimized to tray when I click the Minimize-Button. I write in native C++ with additional use of DX10, DXGI, Direct2D and DirectWrite. I proceed the WM_WINDOWPOSCHANGING. But how did I know if its triggered from a Minimize-Button ( WM_SIZE is already too …

Member Avatar for Mike911
0
213
Member Avatar for harish_s

In my code, I am trying to open a directory of Solaris OS from Windows OS using FindFirstFile(). In Windows XP, the code is working fine but in Window 7 same code is not working. FindFirstFile() returns INVALID HANDLE in Windows 7 and GetLastError() return error code 50, which means …

Member Avatar for harish_s
0
234
Member Avatar for broli100

Hi, I try to make graphic editor with buttons on the left and opengl window on right. Currently I have done it like two windows - opengl and that tool bar.But I want it to be in one window like in most of programs. I have looked for it for …

0
60
Member Avatar for ryan858

OK, what's wrong with this? [CODE=C++] int main(int argc, char* argv[1]) { //declare argc and argv to check command-line arguments string arg = argv[1]; //convert char to string if (argc == 2) { //test if arg was entered if (arg == "test") { //test if arg is 'test' printf("you entered …

Member Avatar for Aranarth
0
85
Member Avatar for ghost_from_sa

Hey guys im having a bit of trouble with bubble sorting an array from a file... Basically what needs to be done is i need to read a text file into a struct array and then copy it into a new file after sorting it by a string field can …

Member Avatar for ghost_from_sa
0
154
Member Avatar for BobbieJean

[COLOR="Red"][I]Hey everyone, I've finally gotten my program to build with no errors or warnings and I can run it but it doesn't give all of the correct output. The Instructor provided my class with what the correct output should be and my program gets it partly right just not all …

Member Avatar for BobbieJean
0
262
Member Avatar for marcoakis

Hello there! I'm new programming in C++, have been learning it for 2-3 months. Now, this uni assignment is working properly, but I'd like to read your advice on how to improve it. All comments are appreciated. Thanks! [CODE] #include <iostream> #include <fstream> #include <string> using namespace std; const int …

Member Avatar for mrnutty
0
77
Member Avatar for gtateco

Hi, I'm trying to do a hashing project using separate chaining. In order to do the separate chaining I believe I need to make a dynamic array of pointers to the linked lists. This is due to the fact the user can specify the hash table size at runtime. In …

Member Avatar for mrnutty
0
3K
Member Avatar for ayan2587

Hello guyz !!! I came across this problem and I am still unable to come up with a good algorithm to solve this problem Problem : given, 1<=n<=1000000, and 1<=k<=9 , calculate the first and last k digits of n^n. for example if n=13 and k=4, then result : first …

Member Avatar for ayan2587
0
191
Member Avatar for eng hassan

[CODE]#include <iostream> #include <conio.h> #include <windows.h> using namespace std; char board[20][20]; void setBoard () { for (int j=0; j<20; j++) { board[0][j] = 219; board[19][j] = 219; } for (int i=0; i<20; i++) { board[i][0] = 219; board[i][19] = 219; } for (int j=1; j<19; j++) { for (int i=1; …

Member Avatar for eng hassan
0
90
Member Avatar for vbx_wx

[code] cout << "Introduceti numele: "; // 1 getline(cin, firstname); cin.ignore(); p.setNume(firstname); cout << "Introduceti adresa: "; //2 getline(cin, adr); cin.ignore(); p.setAdresa(adr); cout << "Introduceti CNP: "; //3 cin >> c_n_p; cin.ignore(); p.setCnp(c_n_p); cout << "Introduceti seria si numarul buletinului: "; //4 getline(cin, serie); cin.ignore(); p.setSerienr(serie); cout << "Introduceti valabilitatea …

Member Avatar for vbx_wx
0
123
Member Avatar for Excizted

Hi people, I'm trying to match strings from a pattern containing[B] wildcards[/B]. Basically I need to be able to go through a stack of strings, and see which of them matches my pattern. Fx [B]My*.txt[/B] will match only one of these. [U]MyFile.txt[/U] [I]MyFile.php[/I] I'm aiming to end up with a …

Member Avatar for NathanOliver
0
5K
Member Avatar for yossi321

Hi How can I protect/lock a drive from deleting files and format it ? Is there a way to hook a drive?

Member Avatar for yossi321
0
59
Member Avatar for programing

Hi, I am write code about stack[pop,push,overflow,underflow] but i think i have Mistake in underflow and overflow .. and how i can Enter any thing in my array .. like if i want to enter [$] or[xxxxx] whatever not only int if you can correct in same code >> [CODE]#include<iostream.h> …

Member Avatar for daviddoria
0
82
Member Avatar for Pynolathgeen

Hello, I've got a pretty much burning question here. Its about BitBlt. I have a window that functions as a button but I wanted to do some markup on it. So I the added BS_OWNERDRAW style to the button, and wanted to BitBlt an image on it. I tried it …

0
73
Member Avatar for Kesarion

If I this function: [CODE] void drawRect(int x1, int y1, int x2, int y2){ HDC screenDC = ::GetDC(0); ::Rectangle(screenDC, x1, y1, x2, y2); ::ReleaseDC(0, screenDC); } [/CODE] How would I clear the screen of the white rectangles ? Can I make them another color ? :)

Member Avatar for Ancient Dragon
0
104
Member Avatar for dmr9215

I'm implementing my own hashtable class as practice, but I'm having trouble retrieving values from the table that were inserted from a file. When I do so from an array however, the program finds the values without a problem... I've tried modifying my hash function to adapt for any potential …

Member Avatar for Radical Edward
0
144
Member Avatar for frenchie4111

[CODE]struct piece { piece(){} piece(int spacs[][3]) { spaces = spacs; } int spaces[][3]; };[/CODE] /home/myname/Programming/C++/blokus1/game.hpp|11|error: incompatible types in assignment of ‘int (*)[3]’ to ‘int [0][3]' How can this be fixed?

Member Avatar for frenchie4111
0
179
Member Avatar for Humaira Qureshi

Hy! I have a project and hav to submit it at 13 june. Can somebody help me to add "Search Code" in this code. Its a student class a data abt student. If i want to search student data printed as Name: Father name: Id: and other data like this …

Member Avatar for daviddoria
0
113
Member Avatar for aay

Write a program that reads in a sentence of up to 100 characters and outputs the sentence with spacing corrected and with letters corrected for capitalization. In other words, in the output sentence, all strings of two or more blanks should be compressed to a single blank. I don't know …

Member Avatar for aay
0
682
Member Avatar for LevyDee

I understand the concept of a binary tree. So I guess, for a programmer defined binary tree, is it basically a doubly linked list except your 2 pointers are your branches?

Member Avatar for Radical Edward
0
74
Member Avatar for daniel88

Hi guys, I am bringing a problem which I thought I had solved, but it has re-reared its ugly head. The problem is one of user input (I can hear you veterans audibly say "Aargh!"). I wish to remove serial numbers (of type string) from a set. To give you …

Member Avatar for daniel88
0
139
Member Avatar for bsse007
Member Avatar for Radical Edward
0
123
Member Avatar for Wikedshorty

I have to write two arrays of 10 random numbers betwwen 1 and 25 then sort those two arrays in increasing order then make a third array that has all the numbers of the first two arrays in sorted order but no duplicate numbers in the third array. Here are …

Member Avatar for Wikedshorty
0
2K
Member Avatar for iXmerof

Hi, I have to write a little game for school. I am new at C++, but I have to do it on SDI. My idea is to make something like this one: [url]http://scratch.mit.edu/projects/Dthen/3801[/url] I have some questions for you: 1. How to remove the status bar from Main Window of …

0
28
Member Avatar for jackman05
Member Avatar for mrnutty
0
315
Member Avatar for BLKelsey

Hi fellas, This week in class (2nd week), we are learning about classes. Our professor has asked us just to complete one simple class with separate files. My problem is when I go to compile, I get errors stating my variables aren't "declared in this scope." As far as I …

Member Avatar for Agni
0
4K
Member Avatar for n30h4x

So my goal for a project of mine, is to output the values of variables into their respected locations in PDF file. Where would I need to look to get started on this? Are there any library's anyone would recommend?

Member Avatar for n30h4x
0
121
Member Avatar for Kesarion

How would I draw something on the screen ? not the console window but the entire screen, preferably with the console minimised. Also, would it show up on a printscreen ? It better not :P What I want to do is create something like a layer on top of the …

Member Avatar for Kesarion
0
118

The End.