
VB CCE/5.0 Enterprise Help
Quote:
> ****Need Help Please****
> I have made a button with VB5 and can't get the OCX to work correctly.
> The button, when clicked opens a form which looks like a menu. (Like your
> start button).
> The problem is that I have to get this form aligned with the form which
> contains the OCX.
> I need the form aligned left of the containing form and directly above
the
> button.
> I have tried the following:
> ....
> MnuForm1.Show
> MnuForm1.Left = UserControl.Left
> MnuForm1.Height = (UserControl.Top - 360)
> ...
Not sure about the second code snipet, but the above will result in an
error if your control.top is less than 360, you can't set an objects height
to negative values, try this...
Load MnuForm
MnuForm.Left = UserControl.Left
MnuForm1.Top = (UserControl.Top - MnuForm.Height)
MnuForm.Show
You don't want to show it then move it, it will look bad, load it,move it ,
then show it.
Mitch