craigsboyd
IS-IT--Management
Can anyone tell me how to find the DISPID for the ComputeControlSize Method of the Monthview control. Or more specifically how to modify the code given at ...to do the following:
I am using Visual C++ to create a DLL to work around a bug in another language. I will be sending a Microsoft MonthView control object to the VC++ DLL and then calling the ComputeControlSize method from within the DLL. What I would like to return is the width and height (parameters 3 and 4 of the ComputeControlSize) from the DLL. I can send the MonthView object and two variables in by reference from Visual Foxpro and I would like these two variables to then hold the values from the ComputeControlSize call in VC++ DLL. For those wondering, I would do it from the Visual Foxpro except there is an undocumented bug preventing this. I have VC++ 6 and think I have a fair handle on most of the code given at the link above, using the MonthView object rather than the Word Application object obviously, however the line that throws me is:
disp.InvokeHelper(0x17, DISPATCH_PROPERTYPUT, VT_EMPTY,
NULL, parms, FALSE);
I am not sure what the DISPID (first parameter) would be or even what should be sent for the remaining paramters. Never done this before. I know I need to use InvokeHelper to make a call to ComputeControlSize for the MonthView object I sent in to the DLL method talkToObject. Any help or direction would be greatly appreciated.
Slighthaze = NULL
craig1442@mchsi.com
I am using Visual C++ to create a DLL to work around a bug in another language. I will be sending a Microsoft MonthView control object to the VC++ DLL and then calling the ComputeControlSize method from within the DLL. What I would like to return is the width and height (parameters 3 and 4 of the ComputeControlSize) from the DLL. I can send the MonthView object and two variables in by reference from Visual Foxpro and I would like these two variables to then hold the values from the ComputeControlSize call in VC++ DLL. For those wondering, I would do it from the Visual Foxpro except there is an undocumented bug preventing this. I have VC++ 6 and think I have a fair handle on most of the code given at the link above, using the MonthView object rather than the Word Application object obviously, however the line that throws me is:
disp.InvokeHelper(0x17, DISPATCH_PROPERTYPUT, VT_EMPTY,
NULL, parms, FALSE);
I am not sure what the DISPID (first parameter) would be or even what should be sent for the remaining paramters. Never done this before. I know I need to use InvokeHelper to make a call to ComputeControlSize for the MonthView object I sent in to the DLL method talkToObject. Any help or direction would be greatly appreciated.
Slighthaze = NULL
craig1442@mchsi.com
"Whom computers would destroy, they must first drive mad." - Anon