In Designer mode

Let us implement a switch.

  1. Create a custom form for the MaterialsAndServices catalog item.
  2. In the form controls tree, double-click the MaterialServiceType field.
  3. In the property palette, in the Type field, select Radio buttons.
  4. In the RadioButtonType field, select Tumbler.
  5. In the ChoiceList field, provide a list that consists of MaterialServiceTypes enumeration values (fig. 28.36).


    Fig. 28.36. Switch field property palette

    Let us also make another change. The Parent field stores the group where a catalog item belongs. And to move an item to the root of the hierarchy, a user should clear this field.

    However, the clear button  is disabled by default. There are other ways to clear the field, such as using the mouse or pressing Delete, but some users really need this button. Let us enable it.
  6. In the Parent field property palette, in the ClearButton field, select Yes (fig. 28.37).


    Fig. 28.37. Text box property palette

    Note that text boxes have other properties that define button visibility: OpenButton, CreateButton, and more. The platform defines their visibility automatically but you can explicitly enable or disable them.

    After the changes the form preview should look as shown in fig. 28.38.


    Fig. 28.38. Catalog item form preview in the form editor
Next page: In 1C:Enterprise mode
Be the first to know tips & tricks on business application development!

A confirmation e-mail has been sent to the e-mail address you provided .

Click the link in the e-mail to confirm and activate the subscription.