And, indeed, you would be right! Thanks!!!!!!!!!!!!!!!!!!!!!!!!
Now we will see if I can tie all this spaghetti together.
Thank you, thank you, thank you for that edit!!!
Edit: And the...
Type: Posts; User: JohnAnon
And, indeed, you would be right! Thanks!!!!!!!!!!!!!!!!!!!!!!!!
Now we will see if I can tie all this spaghetti together.
Thank you, thank you, thank you for that edit!!!
Edit: And the...
Adding to the map now works. Thanks for that.
Calling the function still doesn't.
Tried:
fncRegistry(z)(12.08333); //call z
and various offshoots with the word "call", but the compiler...
Well, trouble is my middle name.
Thanks for sharing.
Thanks. I thought that line was misplaced and questioned its efficacy.
I'll try your suggestion as soon as I re-install VS2008. I'm embarrassed to say that I somehow blew it up by merely trying...
At this point, it appears that the hammer almost works, so if you can bear with me for a few iterations, I would appreciate it.
I have solved the std::map problem by adding a #include <map>.
So...
Well, I've been called worse.
I had already done that since it looked both elegant and promising. On my computer, however, std::map returns compiler error "'map' is not a member of 'std'".
Maybe I can get map from another...
Unfortunately I'm stuck with VC++2008.
Thanks, anyway.
You know, based on the last few responses, I may have miscommunicated.
I'm not building my own separate dll which my bosses routine...
Yes, I'm trying to decipher the code in the example on MSDN. It is late here and it will take me too long to dig out the lines I've interspersed with my other code into a workable display.
I'll...
Indeed it does. Would that it were that were the first suggestion.
Many thanks. Learning, learning, learning.........
I'm not having much luck with understanding how to implement the GetModuleHandle()/GetProcAddress() solution.
I appreciate the suggestion of the internal table, it may very well be a compromise...
Whoosh! That was the sound of your solution wizzing past my head.
First, it is a windows environment.
Second, while I can read documentation as good as the next fella, pseudocode (even BROKEN...
I can't change the signature of MYBOSSESROUTINE from:
double MYBOSSESROUTINE(const char* z)
to
double MYBOSSESROUTINE(SOME_FN z)
All I'm allowed to do is pass him a string with the name...
I looked. I really did. Anyway...
Is it possible in c++ to call a function the name of which is contained in a variable?
Psuedo code (which is a euphemism for I can't write code that works):...
I suppose the fact that I'm stuck with the pointer as an input means that I should go with the original suggestion (strcmp()) and only if I've got some other reason to do string manipulation, which...
Thanks Elysia. You're a programming master! How the hell do you know every thing?
std:string worked just fine, too.
Which is more efficient, std::string or using strcmp?
As a noob to c++ I wouldn't have the foggiest notion of how to implement the "preferred" approach of using std::vector. Since I went to the bother of reducing my code to the smallest possible block...
Then I shall read up on strcmp(). Thanks.
John
Thanks. It worked like a charm. Way cool.
This should be easy. I'm admitting my newness by posting which for most will be, I hope, a simple question.
I'm having trouble testing a string for equality.
double myfunc(const char* z) {...