[Fixed]C++ Issue
#1

Hey. Sorry if this is a dumb question, but i'm a beginner in c++ :/.

Okay, i got following problem:

I made:
pawn Code:
HDC hdc=GetDC(0);
SetPixel(hdc, 100,100, RGB(3,3,0));
I included:
pawn Code:
#include <iostream>
#include <windows.h>
#include <math.h>
#include <fstream.h>
I'm using Dev C++ as a compiler and run this as a console application. When i hit compile it gives me following errors:

Code:
[Linker Error] undefined reference to 'SetPixel@16'
Line 32:2 - Id returned 1 exit status
If you need more information, just tell me.

Would be nice if you would answer, although this might be a stupid question. Thanks!

#edit#: I just found out i forgot linking the libgdi32.o library to the project. Thanks to everyone that reads, anyway.
Reply
#2

Good job, why bother posting here, when you can fix this yourself?
Reply
#3

Quote:
Originally Posted by Seif_
Quote:
Originally Posted by PuukainiiC*
Good job, why bother posting here, when you can fix this yourself?
He needed help and ended up fixing it himself. Why are you getting mad on him?
I'm saying that he should check twice before making an useless topic
Reply
#4

Quote:
Originally Posted by PuukainiiC*
I'm saying that he should check twice before making an useless topic
He's only a human, like you, like everyone else on this forum (except Woet, he might be an animal). Everyone makes mistakes, I'm sure you did this at least one time before.
Reply
#5

He have a problem and asked for it in Everything and Nothing. That is why we have this section for.
Think a little who made useless post(s) in topic.

Now back to topic guys
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)