#Unresolved external symbol

37 messages · Page 1 of 1 (latest)

coral crestBOT
#

When your question is answered use !solved to mark the question as resolved.

Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question run !howto ask.

#

@wild rune

Screenshots!

Your message appears to contain screenshots but no code. Please send code and error messages in text instead of screenshots if applicable!

zealous monolith
#

link

clear lake
#

Where is the function defined?

wild rune
wild rune
clear lake
#

bool __stdcall run(); declares the function. To define it you need to have actual implementation of the function.

wild rune
#

Do I need to declare it right there or somewhere in another file?

clear lake
#

Well you can write the code in the header itself (make sure you mark it inline):

inline bool __stdcall run()
{
    // Implementation goes here.
}
#

Or you put it in a separate source (.cpp) file.

wild rune
#

i have hooks.hpp and i have hooks.cpp

which hooks.hpp in it is just this error

zealous monolith
#

probably don't use __stdcall, that's a microsoft thing

#

or if you do, at least put it on a conditional define

clear lake
zealous monolith
#

and if anything, you probably want __cdecl not __stdcall

clear lake
#

Also in the C++ file if you don't have using namespace is_connected or how the function definition inside namespace is_connected, you need to write bool is_connected::run() for it to match.

zealous monolith
#

I didn't say that was a solution to your problem

#

I'm doubtful you need either of them for what you're doing

wild rune
clear lake
#

Could you show your code?

wild rune
#

Yes now

clear lake
#

This is only the header, where's the implementation?

wild rune
clear lake
#

There doesn't seem to in there.

wild rune
clear lake
#

Did you implement the run function as bool __stdcall hooks::is_connected::run() { } in your cpp file?

clear lake
#

You have not implemented the function hooks::is_connected::run which is the problem.

wild rune
#

how to implement it and where?

clear lake
#

Well you need to write the code for the function.

wild rune
#

what's the code?

clear lake
#

I don't know it's your project.

wild rune
#

Can I show it and can you help me then?