Article ID: 119735
Article Last Modified on 10/30/2003
' Draw line from (20,30)-(200,15)
MyControl.StartX = 20
MyControl.StartY = 30
MyControl.EndX = 200
MyControl.EndY = 150
MyControl.Action = DRAW_LINE
When the custom control receives a message that the Action property is
being set, it can use the information in the StartX, StartY, EndX, and EndY
properties to draw a line.
Declare Function CustomMethod Lib control.vbx (X As Control, ...
Add the following to the VBX code:
int FAR PASCAL _export CustomMethod( HCTL hctl, ...
{
//Perform the custom method on the given hctl.
}
This technique is also used in some Professional Edition controls (for
example, the MSComm control). This technique allows you to pass more than
one parameter to your control, but it also requires slightly more code on
the part of the Visual Basic programmer.
Additional query words: 3.00
Keywords: KB119735