on 03-25-2014 7:11 AM
Hi,
I have designed a layout which contains a table. I need to make some specific rows as BOLD on the table based on some condition like where DATE = space. , these rows are displaying through an internal table. I have placed this table in a sub form.I don't know how to achieve this in adobe forms.
Header 1 | Header 2 | Header 3 |
---|---|---|
DATE | Document number | Credit amont |
Please find the attachment for sample output and the layout.
Quick response would be appreciated.
Thanks for your help in advance,
Suman
Hello Suman,
Don't write the code on individual fields. Write the Javascript code only once directly on the DATA sub form in the Initialize event.
Suppose the field names are DATE, DOCUMENT and CREDIT.
if ( ! this.DATE.rawValue.isNull )
{
this.DOCUMENT.font.weight = "bold";
this.CREDIT.font.weight = "bold";
}
You can refer the below link wherein I have tried and tested. It works fine.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Pavan,
Thanks for the reply, as per your code it is working when date NE space. but my expected output is as below.
Date (Дата) | Document (Документ) | Debet (Дебет) | ||
Opening Balance | 500.00 | |||
03.11.14 | 500000000 | 586,158.70 | ||
03.11.14 | 500000001 | 546,156.59 | ||
03.11.14 | 500000100 | 546,156.59 | ||
03.11.14 | 500000101 | 546,156.59 | ||
03.11.14 | 500000102 | 546,156.59 | ||
Turnover for the period | 2,770,785.06 | |||
Closing Balance | 1,132,315.29 |
Hello Suman,
Well, In that case isNull or == " " won't work.
You have to work conversely(reverse) over here.
What you should do is, set the Font property of all the individual fields in the table as default "Bold" in the Layout as shown below.
Now Write the Javascript code only once directly on the DATA sub form in the Initialize event as shown below.
if ( ! this.DATE.rawValue.isNull )
{
this.DOCUMENT.font.weight = "normal";
this.CREDIT.font.weight = "normal";
}
I have tested it in a test form and it works fine.
You can achieve this requirement through javascript.
Eg:
if ( ! this.CDATE.rawValue.isNull )
{ this.CDOCU.font.weight = "bold";
this.CDEBIE.font.weight = "bold"; }
Please follow the above script to all the fields which you want to display in bold.
---
Naveen
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Naveen,
Thanks for your response. I have tried with the below code as suggested but i cann't see any change in the output.
----- data.Page1.TABLESF1.Free_space.IT_TABLE.DATA.CDATE::ready:form - (JavaScript, client) --------
if ( ! this.CDATE.rawValue.isNull )
{ this.C_DOC.font.weight = "bold";
this.C_CREDIT.font.weight = "bold";
this.C_DEBIT.font.weight = "bold"; }
Please advise.
Thanks
Hi Naveen,
I have maintained the code as advised but it is working in opposite direction.
I want to make the row bold when DATE field space. But now it's making BOLD when DATE field is not initial. I want make other columns as Bold when DATE = ' '. I believe this make sense. I have tried by removing ! from the below code but not working. Please help.
if ( this.DATE.rawValue.isNull )
{
this.DOCUMENT.font.weight = "bold";
this.CREDIT.font.weight = "bold";
}
User | Count |
---|---|
81 | |
10 | |
10 | |
9 | |
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.