on 04-08-2011 10:08 AM
Hello Experts,
I have developed a web dynpro abap application where in I am using interactive forms and generating pdf. I have created design in adobe livecycle designer.
It displays data in pdf form fetching from db view, now I want some rows to be make unvisible at truntime.
i.e I have 5 raws in db view but only 3 raws are filled with data, I dont want the remaining 2 raws to get displayed at all in the pdf form output.
In the adobe livecycle designer, I have created data to be displayed for 5 raws, now the question is how can I dynamically unvisible/hide some of the raws which does not contain any data?
Any valuable input?? (Using Script Editor) how?
Thanks & Regards,
Viral
Edited by: Viralkumar Patel on Apr 8, 2011 11:12 AM
I had a req to make certain rows invisible based on data. It was achieved by adding the below mentioned
code at the form ready event of the column.
if (this.rawValue == "A")
{
this.parent.presence = "hidden";
}
Thanks,
Aravind
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Arvind,
Thanks for the quick reply.
I dont know about scripting so where should I write that code? I also dont understand by rawValue == A as given in your last reply.
Cpuld you please eloborate on this as I am new to this..
Thanks & Regards,
Viral
Edited by: Viralkumar Patel on Apr 8, 2011 12:05 PM
Edited by: Viralkumar Patel on Apr 8, 2011 12:06 PM
Hi Arvind,
Thanks for the support.
As I am very new to scripting, could you please assist me in detail about this that how can I have parameter for that?
My scenario: I have a web dynpro abap application, in that I have developed adobe livecycle interactive forms so that I can display output in pdf. Here I am fetching records from database view and it gets populated in pdf. I have created 5 pages of form in design view, there can be maximum of 5 records in database view, but if that database view has only 3 records then it is displaying the other 2 records(2 pages) as empty as I have 5 different pages for data to be displayed and the remaining 2 pages displays as empty as there is no entry in database view. I want to hide the remaining 2 blank pages to be hide at run time, ie. depending on the records available in database view.
I hope you would be clear with my requirement.
Thanks & Regards,c
Viral
Hi Arvind,
Seems that would work for my requirement as you said.
Could you please tell me in detail about adding subforms and its contents in my form layout so that I can achieve the functionality. I also want to know about hidding the subform depending on the database records.
It would be really helpful for me if you could give further input.
I guess that code I have to write in the script, I dont have idea about scripting for this.
Thanks & Regard,
Viral
Hi Viral,
You will be only having one page with Flowed type. You can set it by going to Object->Subform->Content.
In this way size of the page can increase or decrease. Now you need to have 5 subforms 1 for each record.
Each subform will replace the existing page for each record. So all the UI elements for each record will move into
the sub form.
For hiding the subform, you can check the presence of record. This scripting was discussed earlier in the thread.
It is a very simple script.
Thanks
Aravind
Hi Viral,
if (this.rawValue == null)
{
Subformname.presence = "hidden";
}
The this refers to any UI element which contains data from the db view. If there is none, have a hidden UI element.
Bind it to data from table. In the form ready event of the element you can write the above script. It means if there is
no data make the respective subform hidden. So you need to use subform name second time.
Hope it helps.
Thanks,
Aravind
Hi Arvind,
In my case obj1 is subform name, I want to hide subform1 if it doesnot contain any data. Likewise I have kept the same code in form ready event of obj2, obj3, obj4, obj5 subforms that I want to hide at runtime if doesnot have any data.
Hope these would clarify.
I have made required correction in my code and it is working fine now by doing this.<element> == null in my code.
I found it is displaying correct data but also displaying blank page before seconr page. Any suggestions how can I overcolme this?
Thanks & Regards,
Viral
Edited by: Viralkumar Patel on Apr 14, 2011 6:02 AM
Edited by: Viralkumar Patel on Apr 14, 2011 6:19 AM
Hello,
As you said, I tried to implement that code in scrip but it is still not making hide my subform.
Any valuable suggestions?
Thanks & Regards,
Viral
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
76 | |
9 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.