Logo

Hacker’s Guide to Visual FoxPro
An irreverent look at how Visual FoxPro really works. Tells you the inside scoop on every command, function, property, event and method of Visual FoxPro.

Align

Align is supposedly a property of OLE Controls (the holders for OCXs) that controls the position of their contents on the form. The documentation claims that it applies only to some OLE controls. We don’t think that this is a VFP property at all, but rather a property of OCXs that appears in the VFP property sheet when available.

Usage

oleContainer.Align = nAlign
nAlign = oleContainer.Align

OLE controls are weird. If you put an OLE control on a form, you’ll see some of the properties of the OCX appear on the VFP property sheet. We sure wish they’d given us a clue exactly which controls have an Align property; we haven’t found any yet. But, in any case, we don’t think the documentation for this property belongs in the VFP help file at all.

Example

frmForm.OLEControl.Align = 4

See Also

OLEControl