on 05-07-2010 8:38 PM
Hello ADOBE Forms creators;
I am using the functionality of Strike through(line through) in my PO line items if the line item is deleted. However, in the following line item which is not marked as deleted if some of the fields have the same value as the deleted item, for example: if the quantity in the previous line(the deleted line item) is 5 and in the current line is also 5, this quantity in the current line item which is not marked as deleted gets the strikethrough as well. But if the value is not the same it will not get the strike through.
Can anyone put some light into this issue. The points will awarded to the correct answer(s).
Thanks,
Cyrus
Hello,
could be a strange behavior of the binding. But I cannot tell since you didn´t describe any detail how do you achieve this functionality. I am not aware of any standard mechanism to chieve this, so I expect this is a newly developed one. Can you please tell me how this whole thing should work? Maybe it is a typo or a small script mistake.
Regards Otto
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I am using JavaScript to do this and here is a sample.
Thanks,
if (this.change_text.IND_TXT.isNull == false) {
this.parent.items.NUMBER_INT.font.lineThrough = "1";
this.parent.items.PRODUCT.font.lineThrough = "1";
this.parent.items.DESCRIPTION.font.lineThrough = "1";
this.parent.items.DELIV_DATE.font.lineThrough = "1";
this.parent.items.QUANTITY.font.lineThrough = "1";
this.parent.items.UNIT.font.lineThrough = "1";
this.parent.items.PRICE.font.lineThrough = "1";
this.parent.items.VALUE.font.lineThrough = "1";
this.parent.items.VPER_START.font.lineThrough = "1";
this.parent.items.VPER_END.font.lineThrough = "1";
this.parent.items.del_fr_text.font.lineThrough = "1";
this.parent.items.del_to_text.font.lineThrough = "1";
this.parent.items.YES_NO.font.lineThrough = "1";
this.parent.items.price_undisc.font.lineThrough = "1";
this.parent.items.Net_amt_undisc.font.lineThrough = "1";
}
}
else {
this.presence = "hidden";
}}
What you are seeing is exactly as you described....ie. when the fields match in value, it applies to all. This has do to how you are navigating your DOM there in your Javascript. You are not making use of any indexing....just simply saying "any of my field values for quantity, apply this style". You are "referencing by name" to your fields.
You have:
this.parent.items.QUANTITY.blah.blah
when it should look something like (forgive me but off top of my head....look/search for correct syntax)....
this.parent.list.items[index].QUANTITY.blah.blah
basically you need to find the index of your "QUANTITY" children (and other like named fields). They are all "named" the same, so they will have some kind of index to resolved them correctly. It might be an index after "QUANTITY". I am guessing you will look at the index for IND_TXT and then find all other fields with that same index (ie. same row?).
Hope this helps.
Ok, I found what the problem was:
I entered the above Javascipt code in the Intialization of the Script but this part should go to Doc-ready area of the Script. At the time intialization is too early.
Thanks for everybody's contribution
Edited by: Cyrus Arjomandi on Jun 11, 2010 10:17 PM
User | Count |
---|---|
79 | |
9 | |
9 | |
7 | |
7 | |
6 | |
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.