Calling function exported in a dll..

F

farseer

Hi,
Using a disassembler, i am able to see the exported functions in a dll.
My question is, how do i make a call to those functions and compile my
code if i do not have the header?
 
F

farseer

i swear, this place is really anal about questions asked here it
seems...seems you folks are expecting only those well versed in c++ to
ask questions...either that or everyone gets a kick out posting that
parashift link.

Sometimes, for a novice, it is difficult to know exactly how a question
is categorized...esp if you are not well versed in the language. Does
not matter here however...there seems to be very little tolerance for
those that are trying to learn.

i guess by your response it means in native/ansi c++, it is impossible
to call functions in a dll by inspection...
 
A

Alf P. Steinbach

* farseer:
Using a disassembler, i am able to see the exported functions in a dll.
My question is, how do i make a call to those functions and compile my
code if i do not have the header?

If you ask in [comp.os.ms-windows.programmer.win32] I'll answer it if
nobody else does first.

Here, it's flagrantly off-topic.
 
B

benben

farseer said:
i swear, this place is really anal about questions asked here it
seems...seems you folks are expecting only those well versed in c++ to
ask questions...either that or everyone gets a kick out posting that
parashift link.

Take it this way:

If we did answer your (off topic) question, we would also have to answer
hundreds of other off topic questions asked here from time to time. This
would mess up this group and those who really have a problem regarding
the language would be (unfairly) less attended.

If we did the above, we would as well rename the group to
comp.programming to better convey our topicality. So why not just post
to comp.programming for everyone's sake?
Sometimes, for a novice, it is difficult to know exactly how a question
is categorized...esp if you are not well versed in the language. Does
not matter here however...there seems to be very little tolerance for
those that are trying to learn.

It is not about how you verse your question. Off topic here means one or
more of the following:

non-C++ language-related
platform-dependent
homework

Your question was both non-C++ language related AND platform-dependent.
If you did not know that, now you do.

We are suggesting you to post to other groups for your very best
benefit: that your question will be much better answered in detail there.
i guess by your response it means in native/ansi c++, it is impossible
to call functions in a dll by inspection...

It is indeed impossible with standard C++ (ISO/IEC 14882:2003.) You have
to resolve to platform-specific solutions. Google "DLL call" will get
you started.

Regards,
Ben
 
R

Rolf Magnus

farseer said:
i swear, this place is really anal about questions asked here it
seems...

I guess some are just tired to see the same off-topic question for the
hundredth time.
seems you folks are expecting only those well versed in c++ to
ask questions...
No.

either that or everyone gets a kick out posting that parashift link.

It's this newsgroup's FAQ. It's usually a good idea to mention the FAQ if it
contains something relevant to the question instead of repeating the same
answer over and over and over again. That's what FAQs are there for.
However, it's right that posting just a link to it could be considered a bit
rude. Still that particular FAQ is relevant and helpful.
Sometimes, for a novice, it is difficult to know exactly how a question
is categorized...esp if you are not well versed in the language. Does
not matter here however...there seems to be very little tolerance for
those that are trying to learn.

You're right that it's not good to just assume that the OP knows that an
answer would be off-topic.
i guess by your response it means in native/ansi c++, it is impossible
to call functions in a dll by inspection...

Yes. In fact, the C++ standard doesn't even define DLLs or anything similar.
 
D

Daniel T.

"farseer said:
i swear, this place is really anal about questions asked here it
seems...seems you folks are expecting only those well versed in c++ to
ask questions...either that or everyone gets a kick out posting that
parashift link.

Not at all. After they ask the question and are told that the question
has nothing to do with C++, we expect that they have learned something.
IE we expect that they are not well versed in C++, but they have more
knowledge about C++ than they did before they received the answer they
did.
Sometimes, for a novice, it is difficult to know exactly how a question
is categorized...esp if you are not well versed in the language. Does
not matter here however...there seems to be very little tolerance for
those that are trying to learn.

It does matter, it is important for us to help the questioner categorize
his question. Hence the comments as to where to post said question and
that the question isn't a C++ question.
i guess by your response it means in native/ansi c++, it is impossible
to call functions in a dll by inspection...

There, you learned something about C++. Our task was accomplished. :)
 
M

Mike Smith

benben said:
Take it this way:

If we did answer your (off topic) question, we would also have to answer
hundreds of other off topic questions asked here from time to time.

The respondent could simply have pointed out that no such mechanism
exists in C++, and that therefore the question is not topical, rather
than brushing him off like that. Firm, but gentle.
 
M

Mike Smith

Daniel said:
Not at all. After they ask the question and are told that the question
has nothing to do with C++, we expect that they have learned something.

You'd have a point, if the responder actually *told* the OP that the
question was off-topic and that no such mechanism exists in C++.
Instead, the responder gave the OP the equivalent of "talk to the hand",
which is just rude. I'm as much a supporter of preserving the
topicality of this NG as the next guy, but that doesn't mean we have to
be insufferable pricks while we're doing it.
 
F

farseer

thank you, you've been a great help.
* farseer:
Using a disassembler, i am able to see the exported functions in a dll.
My question is, how do i make a call to those functions and compile my
code if i do not have the header?

If you ask in [comp.os.ms-windows.programmer.win32] I'll answer it if
nobody else does first.

Here, it's flagrantly off-topic.


--
A: Because it messes up the order in which people normally read text.
Q: Why is it such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,819
Latest member
masterdaster

Latest Threads

Top