Hello,
I'm writing a GUI using MFC.
I have a number of press buttons that preform identical tasks on different members of an array.

I know how to make a handler function for each button.
I'm looking for a way to use the same function for all buttons
and within that function to use a SWITCH to distinguish between pressed buttons.

My question is, when using one function for a number of messages, how could I tell which button sent the message?
Is there some function that tells me the ID of the message sender?

Thank you.

Recommended Answers

All 2 Replies

Nice.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.