cancel
Showing results for 
Search instead for 
Did you mean: 

Code for Adobe Forms

Former Member
0 Kudos

Hi Pros,

Where exactly is the code for Adobe Forms written?

I have a requirement of adding a new column to one of the existing tables of a form. I'll illustrate this with an example.

> Imagine we have a 2 Column table. Let's call the columns as A, B.

> A new column C has to be added who's value is A/B.

Where do I have to write this code?

Thanks,

Ravi

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Insert a breakpoint in the driver program or You can do it interface level under code initialization by writing the statement break-point.

Regards,

Nisrin.

Former Member
0 Kudos

I have 2 questions here:

1) Does the code under "Initialization" get called after all the data in the form has been populated or before it happens?

2) I still don't know where to get the Driver Program from. I'm modifying the standard Adobe Form - PTRV_EXPENSE_FORM. So where will the driver program for the standard one be located?

Kindly help.

Thanks,

Ravi

Former Member
0 Kudos

Hi Ravi,

Answering first question,

Code intialization triggers after the data is passed into the respective tables and fields which u are sending via form interface.

Answering second question,

You must be using an transaction to call your output.. If you are doing so then find out which application it belongs to ,

For ex: Va03 transaction belongs to V1 application.

Once u get the application name, Nace-> Select application name-> click output types-> find your output type -> click processing routines-> You will find the program name.

Regards,

Nisrin.

Former Member
0 Kudos

I'm modifying the standard Travel Expense template (HR-FI Module).

The problem I am facing right now is - I am not finding which Output Type the form belongs to in NACE. I looked into all the available output types but none of them seem to match what I am looking for.

Kindly advise if I am missing out onsomething.

The form is PTRV_EXPENSE_FORM.

TCode is PR05.

Former Member
0 Kudos

Hi,

Check out the application P1 and related output type.

Regards,

Nisrin.

Former Member
0 Kudos

I forgot to mention you can check the ouput type which were printed by giving inputs forex: applnkey p1 to table Nast.

Regards,

Nisrin.

Former Member
0 Kudos

How to set breakpoint in the "Code Initialization" part?

Former Member
0 Kudos

In other words, How do I debug the Code Initialization part?

Former Member
0 Kudos

For ex:

Select * from vbap 
                      into table i_vbap 
                      where vbap = '000000198'.
break-point.
if sy-subrc ne 0.
endif.

Regards,

Nisrin.

Former Member
0 Kudos

Hi All,

The problem has been solved... I know it's been real long time since this thread has even started, but its my courtesy to share what I have learnt.

The code should be written in the CODE INITIALIZATION part only, but I found that it was too rigid an editor - so I called a sub-routine of a different program and wrote all my code there!

Thank you all for your help - especially Nisrin!

Ravi

Former Member
0 Kudos

Hi,

Can you please paste what is the code exactly to be written in INITIALIZATION?

thanks

Dan

Former Member
0 Kudos

Hi Ravi,

I have the same issue.Regarding code, i have done the changes as discussed in this forum earlier but i am facing the problem in changes in layout i.e. i need to add a new colomn in Meal per diem table

For this, i have changed the structure for meals per diem table in the interface of the form but when executing the form, the whole table for meals per diem is being disappeared.

Could you please update me on this as it is very urgent.

Thanks & Regrads,

Prabhjot

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi,

You can only code the initialisation code in the transaction.

In SFP , open the interface ,click on Initialisation - > Code Initialisation and in the right hand side window you may write the code.

Other than initialisation coding all the other code may be written in the driver program only.

Please revert back incase of any doubts.

Warm Regards,

R Adarsh

Former Member
0 Kudos

Hi,

I have tried working on Adobe forms... it sure is a challenge!

I have another question... How do I debug these forms? Where do I put the break-point incase I have to see where and how the data is getting fecthed?

Thanks,

Ravi

former_member705122
Active Contributor
0 Kudos

Hi Ravi,

you can add two values by using javascript or Formcalc.

for example go through Help->Adobe LiveCycle Designer Help.

Regards

Adil

Former Member
0 Kudos

Hi,

The code is written in driver program, where the form is called before the two tables are passed an interface.

So whatever changes you need to make you will have to do in the driver programs itself.

Regards,

Nisrin.

Former Member
0 Kudos

Where is the driver program stored? How do I access it?

Former Member
0 Kudos

Hi Ravi,

The Form if it is configured in Transaction NACE , You can see the program name .

Transcation NACE-> Output types->select your output type name-> click on procedure/ routines -> the configuration of your output type will be visible here.

Regards,

Nisrin

Former Member
0 Kudos

Nisrin,

I presume you are speaking about SAP Scripts. I am working on Adobe Forms - TCode is SFP.

Adobe forms does not work that way. They have an "interface" tied with the form and everything happens in that interface. My question is where in this interface is the code written? I might have missed something, but seems like Adobe Forms does not work the way you said it would.

Thanks,

Ravi

Former Member
0 Kudos

Hi,

Yes i have worked with adobe forms though it is tied up with an interface, you still have driver program attached in the transaction NACE.

Regards,

Nisrin.

Edited by: Nisrin Pindwarawal on Jun 20, 2008 1:17 PM

Former Member
0 Kudos

check where this adb form is called.

if this table is passed as an import to the form u need to change it in the program where it is called and in the layout of the adobe form.

if this is decled in form interface then u need to change the table in form interface globel data and then change in the layout.

Former Member
0 Kudos

This is a standard form. The value has to be compiled within the interface.

My question is: where do I actually find the code for the interface. If the adobe form has, say, a table, which contains three rows, where does the data for the three rows come from?

Now if I want to add a new column, where should I write the code for fetching the data for that new column?

former_member188685
Active Contributor
0 Kudos

Adobe forms(Print Forms) and Smartforms/scripts what ever may be you need the Driver program.

Data comes from Driver program to the interface.

If you want to populate the third column we have various options..

1. Using Driver program..

2. In the interface Code initialization you can do that..

3. Run time using Form CALC or Java Script.

If you are not sure please let me know...

Regards

Vijay

Former Member
0 Kudos

Thank you all a lot. I'll try and in case of any hurdles I shall get back.

Regards,

Ravi