Expand my Community achievements bar.

SOLVED

How do I build a table that can be filled in by the user?

Avatar

Level 1

I'm trying to build a form where the user can easily add a qty to order a size. I haven't been able to do this other than adding a text field for every option. Can you build a table that would do the same thing (see my sample below)? Even better, is there a way to get it to total? All ideas appreciated!

Small

Med

Large

XL

Total

Style A

Style B

1 Accepted Solution

Avatar

Correct answer by
Level 10

Hi,

You already have a good start at generating the table. All you need to do is change the cells from static text to either a numeric field or text field. You can do this by dragging a numericField from the Object Library and placing it inside the cell.

Once you have the numeric field in place, you can edit the properties, font, alignment, currency, validation, etc. Then copy and paste the field into similar cells and change the names, for example A_small,  B_small etc.

The "Total" numeric field could have a Formcalc in the calculate event:

$ = A_small + A_med + A_large + A_xl

This is on the basis of a static table where you design all of the rows that will be available to the user.

You can also set up dynamic tables where the uer can add additional rows. There are plenty of good examples in the LC help and on the forums.

Good luck,

Niall

View solution in original post

2 Replies

Avatar

Correct answer by
Level 10

Hi,

You already have a good start at generating the table. All you need to do is change the cells from static text to either a numeric field or text field. You can do this by dragging a numericField from the Object Library and placing it inside the cell.

Once you have the numeric field in place, you can edit the properties, font, alignment, currency, validation, etc. Then copy and paste the field into similar cells and change the names, for example A_small,  B_small etc.

The "Total" numeric field could have a Formcalc in the calculate event:

$ = A_small + A_med + A_large + A_xl

This is on the basis of a static table where you design all of the rows that will be available to the user.

You can also set up dynamic tables where the uer can add additional rows. There are plenty of good examples in the LC help and on the forums.

Good luck,

Niall