cancel
Showing results for 
Search instead for 
Did you mean: 

Adobe form -Non Interactive - Line across when we have any entry

Former Member
0 Kudos

Hi,

In my line items I need a horizontal line separtor based on a field.

I mean when there is an entry(ITEM A) I need it to be underlined alll through the form horizontally or a horizaontal separator line.

I have follwoing output

ITEM A         10.00        20.00
                    40.00        60.00
                    65.00        80.00
ITEM B         30.00        40.00
                    70.00        45.00
                    23.00        22.00
ITEM C         32.00        20.00
                    221.00      60.00
                    65.00        80.00

I need output


ITEM A         10.00        20.00
________________________________
                    40.00        60.00
                    65.00        80.00
ITEM B         30.00        40.00
_________________________________
                    70.00        45.00
                    23.00        22.00
ITEM C         32.00        20.00
__________________________________
                    221.00      60.00
                    65.00        80.00

I am expecting we should do this via javascript.

Any ideas?

Rgds

Vara

Edited by: Vara K on Apr 20, 2009 4:57 PM

Edited by: Vara K on Apr 20, 2009 5:11 PM

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hello!

Not sure if I can see what is the problem here?

Why can't you use usual bottom border for the row of your table?

Or do you need border only for selected items (and no border for others)?

Then yes, your solution is one of possible - you can use JaveScript to change border properties of the row.

But, as a codeless alternative, you can add two row designs (with and without bottom lines) in your table, group them as Choice Section (there is such option in right-click menu) and then control the choice of row design via settings for your Group Section set in the Object palette -> Section -> Type 'Select One Subform from Alternative' and 'Edit Alternatives'.

Regards,

Petr Perstnev

Former Member
0 Kudos

Petr,

thank you for your tips.I guess I haven't explained it clearly.

Here is the issue

example

I have line item A with 5 rows & line item B with 5 rows.

I only need 1 horizontal seperator all the way across the form for these 10 rows .

Key for drawing horizontal line would be my line item number will be blank for 8 rows and will have number for 2 rows.

Rgds

Vara

Former Member
0 Kudos

I'm still not getting the point, cause what you say is (as far as I can see) not the same as what is on your drawing. Do you want to create one table (for "5 rows" and without underlines inside it) inside another table (for line items A,B with underlines for it)? Then this is just what you can do by grouping your data in context. When you then "drop" the table with grouping on the form Adobe Designer will automatically create table inside table. All you have to do is visually format it's borders correctly.

If the data is not grouped in you context (or you can't do it) you still can evaluate the method with group sections and alternatives I have described above.

Or, finally, use your approach with JS.

Former Member
0 Kudos

Okay Petr.

I will be very simple now.Lets say I have 10 rows & 10 columns.

If ROW1 - cell A(column 1) is empty I don't need a line but if cell A (column 1 )is having some value i need a bottom or top line all across the form ( 10 columns ).

Rgds

Vara

Edited by: Vara K on Apr 22, 2009 12:21 AM

Former Member
0 Kudos

Hello!

Finally got it. I'm sorry for such stupidity of mine.

For that case alternatives I described have to do the job just fine.

In the layout of your form create Group Section inside table for items.

In this Group Section create two rows and format them accordingly (with and without underline).

For the Group Section set selection rule to chose correct row (do it under Edit Alternatives).

You have to set it so one row is selected when your first field is filled, and other - when it is empty.

Regards,

Petr Perstnev

Former Member
0 Kudos

Petr,

I am following you now.

I have created a group section with both rows.I went into edit alternatives .

Now I have 2 rows with DATA(0) and DATA(1).

Basically I have to use underlined DATA(0) one when field has no value

and other DATA(0) when field has value.

So basically my pop -up box has javascript

Name: DATA[0]      Binding : DATA

Expression: 
PHCODE.value == "" 

Name: DATA[1]      Binding : DATA

Expression: 

PHCODE.value != "" 

Do i need to write something else in expression for this?

Although I don't have value for that rows Now I am getting bottom lines for every row.

If i use null like below I am only getting rows with bottom lines and remaining are disappearing.

Expression: 
PHCODE.value == null

Name: DATA[1]      Binding : DATA

Expression: 

PHCODE.value != null

Is my expression correct?

What is operator for checking not equal to in javascript? is it !=? or !==?

Rgds

Vara

Edited by: Vara K on Apr 23, 2009 6:05 AM

Former Member
0 Kudos

You can find JavaScript reference in many places online. E.g. [here|http://www.w3schools.com/js/js_comparisons.asp] is one of sources.

I have developed a small example for you based on SAP SPFLI table.

Here's how the resulting PDF will look like: [result|http://www.perstnev.ru/downloads/spfli_result.pdf]

Here's the form itself and XML with data to test it: [example|http://www.perstnev.ru/downloads/spfli.zip]

Open form in the archive in Adobe Designer and examine its properties.

I used FormCalc and <> instead of "!=".

Regards,

Petr Perstnev

Former Member
0 Kudos

Thank you very much Petr for your suggestions & tips.

It worked! I am awarding you full 10 points.

Rgds

Vara

Answers (0)