Click here to Skip to main content
16,008,010 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Access 2000, DAO version ... Pin
Carlos Antollini29-Oct-01 8:51
Carlos Antollini29-Oct-01 8:51 
GeneralRe: Access 2000, DAO version ... Pin
Steen Krogsgaard29-Oct-01 22:37
Steen Krogsgaard29-Oct-01 22:37 
GeneralRe: Access 2000, DAO version ... Pin
Steen Krogsgaard29-Oct-01 22:37
Steen Krogsgaard29-Oct-01 22:37 
GeneralDebug assertion failed getting itemtext from listview Pin
Kuniva29-Oct-01 7:28
Kuniva29-Oct-01 7:28 
GeneralRe: Debug assertion failed getting itemtext from listview Pin
J Patel29-Oct-01 7:56
J Patel29-Oct-01 7:56 
GeneralRe: Debug assertion failed getting itemtext from listview Pin
Alvaro Mendez29-Oct-01 9:45
Alvaro Mendez29-Oct-01 9:45 
GeneralRe: Debug assertion failed getting itemtext from listview Pin
J Patel29-Oct-01 7:57
J Patel29-Oct-01 7:57 
GeneralON_EVENT Pin
29-Oct-01 6:46
suss29-Oct-01 6:46 
Quick question,

I'm trying to use ON_EVENT and I can't seem to figure out what the dispid is.. I pulled the following from MSDN.. I cant make any sense of "dispid".. How can I figure out what value I need to enter for the dispid?

Thanks,
Rob Jones


ON_EVENT( theClass, id, dispid, pfnHandler, vtsParams )

Parameters

theClass

The class to which this event sink map belongs.

id

The control ID of the OLE control.

dispid

The dispatch ID of the event fired by the control.

pfnHandler

Pointer to a member function that handles the event. This function should have a BOOL return type, and parameter types that match the event's parameters (see vtsParams). The function should return TRUE to indicate the event was handled; otherwise FALSE.

vtsParams

A sequence of VTS_ constants that specifies the types of the parameters for the event. These are the same constants that are used in dispatch map entries such as DISP_FUNCTION.

Here is a sample of what I have.. How do I know what to put in for the dispid?
I used a "1" in this example and it works.. But if I add another control I can't seem to use the "1" again.

BEGIN_EVENTSINK_MAP(CSkinDemoDlg, CDialog)
    //{{AFX_EVENTSINK_MAP(CSkinDemoDlg)
	ON_EVENT(CSkinDemoDlg, IDC_OK, 1 /* Click */, OnClickOk, VTS_NONE)
	ON_EVENT(CSkinDemoDlg, IDC_SKINSCROLLBAR1, 1 /* Change */, OnChangeSkinscrollbar1, VTS_NONE)
	//}}AFX_EVENTSINK_MAP
END_EVENTSINK_MAP()



Rob
GeneralPainting an icon into bitmap Pin
krausest29-Oct-01 5:57
krausest29-Oct-01 5:57 
Generalgetting listview item text Pin
Kuniva29-Oct-01 5:56
Kuniva29-Oct-01 5:56 
GeneralRe: getting listview item text Pin
Carlos Antollini29-Oct-01 6:09
Carlos Antollini29-Oct-01 6:09 
Questionc++ forums/contacts and help? Pin
CrazyJim29-Oct-01 5:37
CrazyJim29-Oct-01 5:37 
AnswerRe: c++ forums/contacts and help? Pin
Carlos Antollini29-Oct-01 5:50
Carlos Antollini29-Oct-01 5:50 
GeneralRe: c++ forums/contacts and help? Pin
CrazyJim29-Oct-01 7:39
CrazyJim29-Oct-01 7:39 
GeneralRe: c++ forums/contacts and help? Pin
Carlos Antollini29-Oct-01 7:51
Carlos Antollini29-Oct-01 7:51 
GeneralRe: c++ forums/contacts and help? Pin
Tomasz Sowinski29-Oct-01 9:32
Tomasz Sowinski29-Oct-01 9:32 
AnswerRe: c++ forums/contacts and help? Pin
Rassman30-Oct-01 3:12
Rassman30-Oct-01 3:12 
Generalcreating a special window Pin
29-Oct-01 5:34
suss29-Oct-01 5:34 
GeneralRe: creating a special window Pin
Carlos Antollini29-Oct-01 5:56
Carlos Antollini29-Oct-01 5:56 
GeneralRe: creating a special window Pin
29-Oct-01 7:07
suss29-Oct-01 7:07 
GeneralRe: creating a special window Pin
Carlos Antollini29-Oct-01 7:15
Carlos Antollini29-Oct-01 7:15 
GeneralDirectShow - non-VFW Video Capture - desperate need Pin
#realJSOP29-Oct-01 5:21
professional#realJSOP29-Oct-01 5:21 
GeneralDialog boxes Pin
29-Oct-01 5:17
suss29-Oct-01 5:17 
GeneralRe: Dialog boxes Pin
Joaquín M López Muñoz29-Oct-01 5:35
Joaquín M López Muñoz29-Oct-01 5:35 
GeneralMDI Pin
29-Oct-01 4:55
suss29-Oct-01 4:55 

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.