Click here to Skip to main content
15,912,932 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: winpcap Pin
Bartosz Bien29-Mar-03 11:10
Bartosz Bien29-Mar-03 11:10 
GeneralShellExecute and IE Pin
tinkywinky29-Mar-03 1:51
tinkywinky29-Mar-03 1:51 
GeneralRe: ShellExecute and IE Pin
valikac29-Mar-03 6:13
valikac29-Mar-03 6:13 
GeneralRe: ShellExecute and IE Pin
Anders Molin29-Mar-03 6:55
professionalAnders Molin29-Mar-03 6:55 
GeneralRe: ShellExecute and IE Pin
Stephane Rodriguez.30-Mar-03 8:44
Stephane Rodriguez.30-Mar-03 8:44 
GeneralRe: ShellExecute and IE Pin
tinkywinky30-Mar-03 9:10
tinkywinky30-Mar-03 9:10 
GeneralMFC and dynamic button Pin
Sztahoo28-Mar-03 23:00
Sztahoo28-Mar-03 23:00 
GeneralRe: MFC and dynamic button Pin
Brian Shifrin29-Mar-03 2:41
Brian Shifrin29-Mar-03 2:41 
>I have a dialog and I create button [myButton->Create(...)].

>1. When I use OnLButtonDown in my dialog, it doesn't react when myButton
>is clicked. I want to know when my dynamic button is clicked.

Why should it, after all you clicked on button, not the dialog.

>How to recive messages from this dynamic button?

There are number of ways you can get notified when user clicked on child control....

When you creating myButton you are passing handle for the parent CMyDialog....

1) Add public member CMyDialog::ButtonPressed(CString& strName), override inside CmyButtonClass::OnLButtonDown to do something like
{
CMyDialog *pDlg = (CMyDialog *) GetParent();
pDlg->ButtonPressed(CString("myButton");
}

2) You can define own custom message and send it to parent...

3)....

Brian
In CmyButton::OnLButtonDown() you could GetParent()

GeneralRe: MFC and dynamic button Pin
Bartosz Bien29-Mar-03 11:12
Bartosz Bien29-Mar-03 11:12 
GeneralSubclass dialog item Pin
John-theKing28-Mar-03 22:33
John-theKing28-Mar-03 22:33 
GeneralRe: Subclass dialog item Pin
PJ Arends29-Mar-03 9:42
professionalPJ Arends29-Mar-03 9:42 
Generaloverloading operators..Plesae help Pin
Tozilla28-Mar-03 21:44
Tozilla28-Mar-03 21:44 
GeneralRe: overloading operators..Plesae help Pin
PJ Arends29-Mar-03 10:51
professionalPJ Arends29-Mar-03 10:51 
GeneralRe: overloading operators..Plesae help Pin
Tozilla29-Mar-03 20:42
Tozilla29-Mar-03 20:42 
Questionhow to draw a picture Pin
snollow28-Mar-03 20:33
snollow28-Mar-03 20:33 
AnswerRe: how to draw a picture Pin
Brian Shifrin29-Mar-03 2:48
Brian Shifrin29-Mar-03 2:48 
GeneralRe: how to draw a picture Pin
snollow30-Mar-03 16:19
snollow30-Mar-03 16:19 
Generalwinsock Pin
moraalg28-Mar-03 15:38
moraalg28-Mar-03 15:38 
GeneralRe: winsock Pin
valikac28-Mar-03 16:20
valikac28-Mar-03 16:20 
GeneralRe: winsock Pin
Rickard Andersson2029-Mar-03 10:21
Rickard Andersson2029-Mar-03 10:21 
GeneralRe: winsock Pin
Moak28-Mar-03 17:23
Moak28-Mar-03 17:23 
QuestionHow do I change the ip address of my computer?? Pin
IrishSonic28-Mar-03 15:36
IrishSonic28-Mar-03 15:36 
AnswerRe: How do I change the ip address of my computer?? Pin
moraalg28-Mar-03 15:40
moraalg28-Mar-03 15:40 
GeneralAdding a tab to the output window in vc6 Pin
Martin Slater28-Mar-03 15:06
Martin Slater28-Mar-03 15:06 
GeneralGet Error__ left of '.point' must have class/struct/union type Pin
wow999928-Mar-03 14:26
wow999928-Mar-03 14:26 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.