on 07-31-2009 8:40 AM
I have a Subform and inside that subform three fields and one Static text field for the header. It looks like :
Subform->
StaticText.
Field 1.
Field 2.
Field 3.
Now if all the three fields are empty , then Static Text should hide. If any one field has a value, Static text should appear.
The fields which are empty should also hide.
For individual field to hide when there is no data I have written FormCalc Script :
if ( not hasValue( $) ) then
$.presence = "hidden".
endif
How to hide Static Text when all fields are empty ?
Hi,
Place a Text Field from the library and in Object Pallete make its presence as Hidden(Exclude from Layout).
Goto Script Editor for this field
Event : Validate Script Language: Formcalc
place the below code
if ( not hasValue( subform.field1 ) and not hasValue( subform.field2 ) and not hasValue( subform.field3 ) ) then
subform.StaticText.presence = "hidden"
else
subform.StaticText.presence = "visible"
endif
Thanks,
Madhu.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
88 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.