Try:
<mx:Canvas label="Cause" width="100%" height="100%" id="cause">
<mx:HBox width="100%" horizontalAlign="center">
<accidents:causes id="Cause"/>
</mx:HBox>
</mx:Canvas>
--- In [email protected], "markgoldin_2000"
<[EMAIL PROTECTED]> wrote:
>
> Is there a way to center a form horizontally? Here is my code:
>
> <mx:Canvas label="Cause" width="100%" height="100%" id="cause">
> <mx:HBox horizontalAlign="center">
> <accidents:causes id="Cause"/>
> </mx:HBox>
> </mx:Canvas>
>
> where causes is an mxml component based on a form. When I run this
code
> the form is positioned on the left side of the box.
>
> Thanks
>