cancel
Showing results for 
Search instead for 
Did you mean: 

Adobe Print form (non java)

Koja78
Participant
0 Kudos

Hi,

With a condition you can hide the contents of a field but it seems you cannot hide the caption.

What is the workaround for this as I would like the whole field to disappear.

Regards

Accepted Solutions (1)

Accepted Solutions (1)

pavan_prabhu
Active Participant

Hello Koenraad,

     Wrap the whole field in a sub form. Then write the condition on the sub form itself. So when the condition is true, the whole sub form is hidden and the complete field with the caption and value will be hidden.

Answers (6)

Answers (6)

Koja78
Participant
0 Kudos

if (CONTACT_FAX.rawValue == null) {

this.presence = "invisible"; }

works...

The syntaxcheck is just completely worthless

Koja78
Participant
0 Kudos

There must be something horribly wrong with my syntax as even the following doesn't work


var x = 5;
var y = 5;

if (x = y) {
this.presence = "invisible";
}

ali_eshaghibeni
Participant
0 Kudos

HI

it seem you got the answer, but i think it is really worth to have copy of this two PDF from Adobe, there are like a light in your way to master your self in Adobe Form Syntax.

FormCalc User Reference

http://help.adobe.com/en_US/livecycle/es/FormCalc.pdf

LiveCycle® Designer ES Scripting Basics

http://help.adobe.com/en_US/livecycle/8.2/LiveCycle_Designer_Scripting_Basics.pdf

Second book provides Java and Form Calc codes beside each-other.

Hope you find them helpful.

Regards,

Koja78
Participant
0 Kudos

Still busy on it.


if ( $.SUBFORM_CONTACT_FAX.CONTACT_FAX.value == NULL ) then

$.SUBFORM_CONTACT_FAX.presence = "hidden"

endif

clearly didn't work.

ali_eshaghibeni
Participant
0 Kudos

What about : .presence = "invisible"

are you sure your condition is working fine?

Koja78
Participant
0 Kudos

It is definitely the condition  which is wrong

Without condition the field & label are invisble.. or hidden.. whatever I choose

ali_eshaghibeni
Participant
0 Kudos

if you wanna check the field value weather its Null or not i suggest you to use like this:

($.SUBFORM_CONTACT_FAX.CONTACT_FAX.isNull)


BASED ON MY EXPERIENCE most of time isNull is much more reliable in codes.

Koja78
Participant
0 Kudos

My initial attempt was with a context condition.  Which hides the content of the field but not it's caption.  But I get now that I should use a script in layout mode.  (im a virgin in adobe forms.. it's my first   )

ali_eshaghibeni
Participant
0 Kudos

Its good you were able to handle this problem.

ali_eshaghibeni
Participant
0 Kudos

How did you hide the content? if you are doing this with code in condition rules you can invisible the whole field with such code:

fieldname.presence = "invisible"


hope this helps,

Koja78
Participant
0 Kudos

How do you visualise the subform in the context tab in order to put a condition?