Overview | Module | Use | Devguide | Index

Methods' Summary | Attributes' Summary | Methods' Details | Attributes' Details

:: com :: sun :: star :: form ::
interface XFormsSupplier
Description provides the access to a collection of forms.

Methods' Summary
getForms | accesses the forms.

Methods' Details
getForms
::com::sun::star::container::XNameContainer
getForms();
  Description accesses the forms. Example StarBASIC
       REM ***** BASIC *****

       Sub createColorSelectionBox
       ' create a new shape
       xShape = thisComponent.createInstance( "com.sun.star.drawing.ControlShape" )
       Dim aPos as new com.sun.star.awt.Point
       aPos.X = 200
       aPos.Y = 100
       xShape.Position = aPos
       Erase aPos
       Dim aSize as new com.sun.star.awt.Size
       aSize.Width = 2500
       aSize.Height = 5000
       xShape.Size = aSize
       Erase aSize

       ' create a combo box model
       xControlModel = thisComponent.createInstance( "com.sun.star.form.component.ComboBox" )
       xControlModel.Name = "ColorSelection"
       xControlModel.Text = "red"

       ' marry the shape and the model
       xShape.Control = xControlModel

       if ( 0 = thisComponent.DrawPage.Forms.getCount() ) Then
       xForm = thisComponent.createInstance( "com.sun.star.form.component.DataForm" )
       xForm.Name = "SampleForm"
       thisComponent.DrawPage.Forms.insertByIndex( 0, xForm )
       End If
       ' insert the control model into the first form of the forms collection of the
       ' draw page of the document
       thisComponent.DrawPage.Forms.getByIndex(0).insertByIndex( 0, xControlModel )
       thisComponent.DrawPage.add( xShape )
       End Sub
Returns the container of all the top-level forms belonging to the component.

Top of Page

Copyright © 2000, 2014 LibreOffice contributors and/or their affiliates. All rights reserved.

LibreOffice was created by The Document Foundation, based on OpenOffice.org, which is Copyright 2000, 2010 Oracle and/or its affiliates.

The Document Foundation acknowledges all community members, please find more info at our website.

Privacy Policy | Impressum (Legal Info) | Copyright information: The source code of LibreOffice is licensed under the GNU Lesser General Public License (LGPLv3). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.