921 Posted Topics

Member Avatar for William Hemsworth

Whats the highest score you can get ?? [URL="http://www.ferryhalim.com/orisinal/g3/00bells.swf"]Link[/URL] My best sofar is 1,113,870 :) Have fun.

Member Avatar for maydhyam
0
94
Member Avatar for sbbs05

Read [URL="http://www.catb.org/~esr/faqs/smart-questions.html#homework"]this[/URL].

Member Avatar for jencas
0
150
Member Avatar for mimo77

[QUOTE=yoyo0;673325]is it gooooooooooooooooooood????????[/QUOTE] Nope.. read Salems post...

Member Avatar for papuccino1
-1
197
Member Avatar for astropirit

I agree with [B]Salem[/B], I dont like to encourage cheating.. but heres somebody who has already solved this problem. [URL="http://www.daniweb.com/forums/post663383.html#post663383"]Link[/URL]

Member Avatar for William Hemsworth
0
103
Member Avatar for abhigame

Ever heard of a search engine ?? [url]http://www.google.co.uk/search?hl=en&q=library+sort&btnG=Google+Search&meta=[/url]

Member Avatar for ArkM
0
111
Member Avatar for c#loser
Member Avatar for c#loser
0
80
Member Avatar for Arabule

Look at [URL="http://www.daniweb.com/forums/thread24999.html"]this thread[/URL]. Try asking for your username to be changed there.

Member Avatar for Arabule
0
97
Member Avatar for mksakeesh
Member Avatar for TheBeast32

I wrote a slightly evil code, which I decided not to put up as a code snippet because it completely stops you from doing ANYTHING with the mouse or keyboard :) The only way to get out of it is to either log off (may only work on some computers) …

Member Avatar for TheBeast32
1
341
Member Avatar for Alex Edwards

Data stored in classes / structures is not seperated by anything, it can almost be though of as a complex array that can hold different data types. That is how you can use [B]reinterpret_cast[/B] so that another structure, or even just an array can get the data from the structure. …

Member Avatar for Alex Edwards
0
162
Member Avatar for ichigoSJ

I think you need to describe what it is your making and what your is problem a little better. Simply saying [B]i'm stuck[/B] isn't enough.

Member Avatar for Radical Edward
0
115
Member Avatar for Wiki_Tiki
Member Avatar for William Hemsworth
0
176
Member Avatar for veeran

You have to use double backwards slash, try changing it to this. [CODE=CPLUSPLUS]CreateDirectory(_T("c:\\program files\\Testing"))[/CODE] Hope this helps.

Member Avatar for William Hemsworth
0
190
Member Avatar for daviddoria

Try this. [CODE=CPLUSPLUS] class Point { public: double x; double y; Point() { x = 0; y = 0; } Point(double _x, double _y); x = _x; y = _y; } Point &operator =(const Point &p) { x = p.x; y = p.y; return *this; } }; [/CODE]

Member Avatar for Narf!!!
0
213
Member Avatar for THAPELO

[QUOTE=gregorynoob;669860]I'll just hope you're not in highschool yet so...here's the first function you'll need...it's pretty straightforward: [code]char letter( int mark ) { if( mark <= 39 ) return 'F'; else if( mark <= 49 ) return 'E'; else if( mark <= 59 ) return 'D'; else if( mark <= 69 …

Member Avatar for Narf!!!
0
104
Member Avatar for bhoot_jb

[QUOTE]In WinProc() I think you need to add code for WM_CREATE.[/QUOTE] You dont need anything there, it is simply for any extra things you want to do just before the window displays. Ok, theres quite a few problems in this code, I will list a couple of them. [LIST] [*]Your …

Member Avatar for William Hemsworth
0
191
Member Avatar for ChroNoS

Thanks for using code tags on your first post :) its not often that happends. Some of your indentation is a bit strange so I will fix that up, I also removed one warning to do with signed / unsigned comparisons. [CODE=CPLUSPLUS] #include <iostream> #include <string> #include <iomanip> #include <string.h> …

Member Avatar for ChroNoS
1
107
Member Avatar for astrogirl77

This is pathetic, honestly. Instead of trying to pay people to do this simple task you could do in a couple of hours, show some effort and do it yourself. Remember we are only here to offer help, not to do it for you.

Member Avatar for William Hemsworth
0
133
Member Avatar for nimloman

To be honest, that didnt really help as all the indentation has been lost (assuming it was there in the first place)

Member Avatar for Radical Edward
0
211
Member Avatar for Shanti C

Yeh, thanks to [B]Ancient Dragon[/B] I think theres been some moments when I have had higher reputation than post count :)

Member Avatar for William Hemsworth
0
86
Member Avatar for Dani

The forums don't update in realtime like the [B]Subscription Spy[/B]. It would be great if it did :)

Member Avatar for William Hemsworth
0
997
Member Avatar for nnhamane

[B]muraliaa[/B], that has got to be one of the worst written codes ever, the indentation is all messed up, you havent used code tags, and you have your [B]void main[/B]. Also you havent added any files to include, so the functions [B]printf[/B], [B]getch[/B] and [B]clrscr[/B] are all undefined. I wouldent …

Member Avatar for Salem
0
1K
Member Avatar for mksakeesh

Oh boy, where to start.. First, learn to use [B]code tags[/B], its not difficult. Give more details on your problem, and show the errors you are getting. Dont use [B]void main[/B]. Try posting this again, but this time.. properly and then I will help you with your problem. Read this …

Member Avatar for Clockowl
0
162
Member Avatar for atish00

Pointing to a 2D array is just like pointing to a 1D array, all the pointer does it point to the very first element of the array. Heres an example that shows how you can point to multi-dimensional arrays by using pointers. [CODE=CPLUSPLUS] #include<iostream> using namespace std; void DisplayNums1D(int *nums, …

Member Avatar for atish00
0
271
Member Avatar for dumbokia

Yes, use code tags, post specific question and errors if there are any, your not going to get much help unless you do. :icon_neutral:

Member Avatar for William Hemsworth
0
105
Member Avatar for soppyhankins

I suggest you change the structure of your code to look something more like this. Handle all key events and make them only change the velocity, not the actual sprite location. Then at the end, when you have done all the key event handling, then add the velocity to the …

Member Avatar for soppyhankins
0
252
Member Avatar for robertmacedonia

Its your choise if you want to include namespaces, but they are there for a reason, mainly for structuring your code and avoiding name confliction. Take this example: [CODE=CPLUSPLUS] #include <iostream> namespace A { int var = 10; }; namespace B { int var = 20; }; using namespace A; …

Member Avatar for William Hemsworth
0
256
Member Avatar for iansane

[B]system()[/B] takes a char array (pointer) as an argument, if you want to run an application you could use this simple function. [CODE=CPLUSPLUS] void Run(char *app) { std::string command = "start "; command += app; system(command.c_str()); } [/CODE] Now to call that function it should look something like this. [CODE=CPLUSPLUS] …

Member Avatar for iansane
0
296
Member Avatar for Black Magic

While your adding numbers to the array, just check if the array already has the value, if so, then try again. This seems to do the trick. [CODE=CPLUSPLUS] #include <iostream> using namespace std; int main() { int i, j, k, randomNumber[10]; for(i = 0; i < 10; i++) { randomNumber[i] …

Member Avatar for ArkM
0
385
Member Avatar for ciencia

> Also, why use 3.14 when you already defined PI ? I get the feeling that he didn't write this code, and didn't take the time to look through it first to see what resources have already been given. If he did write the code, then im amazed that he …

Member Avatar for William Hemsworth
0
125
Member Avatar for vvim
Member Avatar for jack1234

Try this: [CODE=CPP] #include<windows.h> #include<iostream> #define DebugMessage(str) OutputDebugString(str) int main() { DebugMessage("Hello"); std::cin.ignore(); return 0; } [/CODE]

Member Avatar for bugmenot
0
3K
Member Avatar for FTProtocol

This sounds like a tricky project, for your first question, try looking up windows [URL="http://msdn.microsoft.com/en-us/library/ms644990.aspx"]hooks[/URL]. It is most lightly what your looking for. For your second quesion I think you have to scan through each child window, mabey by using [URL="http://msdn.microsoft.com/en-us/library/ms633494.aspx"]EnumChildWindows[/URL] with the web browser and somehow read each word, …

Member Avatar for William Hemsworth
0
131
Member Avatar for williamnz

Not saying you should use it, but one way is to remake the structure with the same variable types and sizes, but leave all the members public, heres an exmaple. [CODE=CPLUSPLUS] #include<iostream> using namespace std; class A { private: int a; public: A() { a = 10; } }; class …

Member Avatar for William Hemsworth
0
395
Member Avatar for williamnz

A few things you should add if your defining the function within the class. [CODE] [COLOR="Red"][B]friend[/B][/COLOR] ostream &operator<<(ostream &cout,MyClass [COLOR="Red"][B]&[/B][/COLOR]obj) { cout << "Output members here."; return cout; } [/CODE]

Member Avatar for williamnz
0
2K
Member Avatar for kneel

If you want to find a name and display the telephone number you have to loop through each person in the address book and then use the [URL="http://www.cplusplus.com/reference/clibrary/cstring/strcmp.html"]strcmp[/URL] function which takes two char pointers as parameters and returns 0 if they match. It would look something similar to this: [CODE=CPLUSPLUS] …

Member Avatar for Ancient Dragon
0
260
Member Avatar for QuantNeeds

>I cannot get this string to store in the array appropriately. exactly what do you mean by this ?? whats going wrong ? :-/

Member Avatar for ArkM
0
83
Member Avatar for William Hemsworth

Hi everyone. Here is a program I made which will find patterns in a list of primes. It does this by finding the difference between each prime and adding them to a vector like this: [CODE] Primes: 2 3 5 7 11 13 ^ ^ ^ ^ ^ Difference: 1 …

Member Avatar for Prabakar
0
159
Member Avatar for kavithabhaskar
Member Avatar for Wiki_Tiki

I had this problem many times, its not vista, you have to make sure that the program configuration is set to "Release" instead of "Debug". But I came across so many of these errors when using .NET and got tyred of it, so I stopped using it and have never …

Member Avatar for Tigran
0
142
Member Avatar for coveredinflies

[QUOTE=CoolGamer48;654551] If you really want to know how to convert a string to an array: [CODE] char strarray[100]; string str = "Hello"; for(int i = 0;i < str.length();i++) strarray[i] = str[i]; [/CODE] [/QUOTE] This will work, but in future when copying variables like this from a vector, try to do …

Member Avatar for CoolGamer48
0
4K
Member Avatar for kneel

> 2. Pointers degrade reliability of C++ programs due to security issues I try to only use pointers when necessary, if your not going to be accessing others parts of the memory from that pointer, then simply use references. This will also make the code more readable.

Member Avatar for oliver_mk
0
66
Member Avatar for 11silversurfer1

Try adding this: [CODE] case WM_LBUTTONDOWN: { float mx = 0;//mousex float my = 0;//mousey mx = LOWORD(lParam); my = HIWORD(lParam); [COLOR="Red"][B]POINT mp; mp.x = mx; mp.y = my; ScreenToClient(hwnd, &mp); mx = mp.x; my = mp.y;[/B][/COLOR] return (0); } [/CODE]For more information look [URL="http://msdn.microsoft.com/en-us/library/ms533179(VS.85).aspx"]here[/URL]. [I]edit: I just realised this …

Member Avatar for 11silversurfer1
0
328
Member Avatar for guy40az
Member Avatar for CoolGamer48
0
153
Member Avatar for jack1234

Yes, windows tend to do that for alot of types, and sometimes theres no need for them, for example in one of the header files I found these: [CODE=CPP] #define CONST const typedef int INT; typedef float FLOAT; [/CODE] and hunderds more.. ;)

Member Avatar for CoolGamer48
0
127
Member Avatar for TheBeast32

funnily enough, I have just finished making the exact same thing :), take a look at it if you like, its pretey cool and allows you set set playback speeds & more. Hopefully I will also help you with your problem. My one saves all the data in pure binary, …

Member Avatar for TheBeast32
0
344
Member Avatar for C_isoundu

This example will read each word from a file, allow you to make the changes you want, and then write them back. The only problem with this example is that all indentation and extra spaces will be lost. To do it properly, you will have to load the entire file …

Member Avatar for William Hemsworth
0
104
Member Avatar for Shadoninja
Member Avatar for Shadoninja

To use the [B]srand[/B] function with [B]time(0)[/B] you must include [B]<ctime>[/B]. Where as for the first one, I think you have to use a plain char array and then convert that to type [B]string[/B]. It would also help if you showed the errors MSV was giving.

Member Avatar for Narue
0
181
Member Avatar for mhil_joy
Member Avatar for William Hemsworth
0
172

The End.