This is a migrated thread and some comments may be shown as answers.

Multiple Form Fields on same row

1 Answer 1057 Views
Form
This is a migrated thread and some comments may be shown as answers.
Marc Simkin
Top achievements
Rank 2
Iron
Veteran
Iron
Marc Simkin asked on 22 Mar 2021, 02:16 PM

Hi.

If I understand everything correctly, there is a one-to-one relationship between the <FormItem> element and model's data field.

I am aware that I can use a <FormGroup> and set the columns attribute to indicate how many columns are needed.  However, each <FormGroup> element renders a <fieldset> and <legend> element.

Is it possible to place two, or more, data fields inside of one <FormItem>'s <Template> element?

I'm looking for a way to not waste screen space by having each element of my form on it's own row.  Using a <FormGroup> helps, however, I would like to avoid having all the extra <fieldset> and <legend> elements rendered.

Thanks

1 Answer, 1 is accepted

Sort by
0
Accepted
Marin Bratanov
Telerik team
answered on 24 Mar 2021, 05:32 PM

Hi Marc,

The FormItem is an item in the layout of the form that matches the columns and settings the form has. It it just a <div> element, no fieldsets or serious limitations here (but keep in mind we do have some CSS rules that might affect your content).

You are free to add your own content and editors in it. If you want, you could add more than one textbox, for example.

What you are looking for might be, however, better served by your own HTML layout inside a standard <EditForm> - you will have total freedom there to generate the layout, columns and design you want.

Regards,
Marin Bratanov
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
Form
Asked by
Marc Simkin
Top achievements
Rank 2
Iron
Veteran
Iron
Answers by
Marin Bratanov
Telerik team
Share this question
or