Announcement

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

    How can a button be placed in an arbitrary cell of a a dynamic form?

    Hi,

    for example in the the code below setting the value of numCols from 2 to 4, 6 etc the textitmes are spreading across the columns as expected. But the createAccount button is always at the begining of a new row. Independently of the value of numCols.

    How can a button be placed in an arbitrary cell of a a dynamic form?

    Greetings Thomas

    Code:
     isc.DynamicForm.create({
        width: 250,
        numCols:6,
        fields: [
            {name: "username",
             title: "Username",
             type: "text",
             required: true,
             defaultValue: "bob"
            },
            {name: "email",
             title: "Email",
             required: true,
             type: "text",
             defaultValue: "bob@isomorphic.com"
            },
            {name: "password",
             title: "Password",
             required: true,
             type: "password",
             validators: [{
                type: "matchesField",
                otherField: "password2",
                errorMessage: "Passwords do not match"
             }]
            },
            {name: "password2",
             required: true,
             title: "Password again",
             type: "password"
            },
            {name: "createAccount",
             title: "Create Account",
             type: "button",
             click: "form.validate()"
            }
        ]
    });

    #2
    ButtonItems are startRow/endRow:true by default - just switch those off in your button's field-definition.

    Comment


      #3
      thanks for the quick response. That did it!

      Regards Thomas

      Comment

      Working...
      X