2.4 Changing the Appearance of Fields - Forum - Rollbase - Progress Community

2.4 Changing the Appearance of Fields

 Forum

2.4 Changing the Appearance of Fields

  • This sample is not working - could you review and let me know if there are aerrors in the sample? 2.4 Changing the Appearance of Fields Often, behavior of one field should depend on a selection made in another field. Consider the example below, in which there are three fields: • Club Member (checkbox) • Membership Fee (currency) • Member Since (date) The last two fields should only be available if “Club Member” is checked. To achieve this, take following steps: 1. Create a script component on the Page with the following code: Tip: Use prefixes (like my_ prefix in the example above) to avoid naming conflicts. Note that Rollbase JavaScript system functions have the prefix rbf_ , and system variables have the prefix rbv_ . 2. Add event handling code to the “onclick” event of the “Club Member” checkbox
  • All examples were tested before including in documentation. What exactly is not working? Do you see any JavaScript errors in your browser?
  • I created the same fields yo used in the example and copy pasted the exact code - it does not disable the fields.