Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Order of Items in a DynamicForm

    I have a DynamicForm, and I would like to add 3 buttons in a row in the last row of the DynamicForm

    m_itemType
    m_itemShortDescr,
    m_itemSize,
    m_itemPhone,
    m_itemEmail,
    m_itemComments,
    m_temBtnNew, m_itemBtnUpdate, m_itemBtnDelete

    the last 3 items should be in the same row.
    Is this possible to be done? and how could I do it?

    Thank you again for your help.

    #2
    hello

    you can call the setBeginRow (not sure of the name but it's something like that) on your first button. If you set a number of columns to 3 or greater your buttons will be displayed on the same row ;)

    Regards

    Comment


      #3
      FormItem.setStartRow(boolean), FormItem.setEndRow(boolean)
      It is very helpfull and it works fine,
      thank you.

      Comment


        #4
        The second Button appears at the second column and so forth.

        Is it possible to ignore the columns?
        For example to add some kind of panel that will span all the columns and add the buttons inside this new panel?
        I didn't see something like this in the help.

        Thank you again.

        Comment


          #5
          A typical DynamicForm for me has a VLayout with different forms embedded in it. I have even used HLayout of DynamicForms within a VLayout to get desired results. It might be helpful to play with some of the combinations in Visual Builder to get a feel for what's possible.

          So for your specific situation, instead of creating a Dynamic form with your fields and button in it, create a VLayout with the fields in a form at the top and another dynamic form at the bottom. Each form can have different column layouts. Just use the VLayout where you currently use your form. See this article for an example.

          Note that if your dynamic forms are sharing a datasource you will want to read up on the ValuesManager.

          dave

          Comment


            #6
            Just a general note that wherever your form is essentially tabular (breaks down neatly into columns), you should just use the built-in table-based layout of the DynamicForm, covered in the Form Layout overview.

            David's approach is the "next step" beyond that, for a form that is at least partially non-tabular, and in this case using VLayouts, HLayouts or custom layout classes is the right approach.

            However don't start laying out forms by using one DynamicForm per FormItem with everything else being Layouts :) Break up the form into different layouts only where you are required to because you have two parts of the form that don't have corresponding columns.

            Comment

            Working...
            X