cancel
Showing results for 
Search instead for 
Did you mean: 

Variables not accessible in script

Former Member
0 Kudos

Hi,

I have a requirement to print an invoice form on the click of SAVE button in transaction VF02.

I have created a Z script and a driver program.

FO has configured both these in transaction NACE.

The entry in TNAPR is also displaying correctly i.e my driver program is reflecting in program name corresponding to the entry in script.

But when i check in SE71. FORM->CHECK->TEXTS->click 'tick'.

At this point, driver program name is SAPMV60A (Processing billing documents) because of which variables of my deiver's program name are not accessible in script.

I manually appended the name of my driver program in script but of no use.

Values of variables from driver program are still not accessible in script.

According to functional, setting are correct.

Please provide your inputs on this.

Regards,

Richa

Edited by: richa.aggarwal1988 on Mar 9, 2012 6:23 AM

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member189779
Active Contributor
0 Kudos

HI

Is your custom print program gets triggered?

Also have you used OPEN_FORM START_FORM WRITE_FORM END_FORM CLOSE_FORM correclty?

Regards

Vinit

Former Member
0 Kudos

Hi,

My custom print program is getting triggerred.

I checked all the FM's open_form, write_form and close_form.

All are properly written.

Please help..!

Regards,

Richa

former_member189779
Active Contributor
0 Kudos

Hi

Is your driver program is copy of standrd program? Can you mention few more detials aboout program you are using?

What is configured in NACE in Program, Form Routine and Form?

Former Member
0 Kudos

The program is not the copy of standard program.

It is a simple z program with some fetching logic.

With this program i am also getting a dump called 'Express document: update was terminated" whenever i try to change or create billing document of my output type.

can you help on this??

Regards,

Richa

former_member189779
Active Contributor
0 Kudos

To trigger a form from output type:

1. Make a copy of standard program RVADIN01 for SAP Script and if SMARTFORM Program RLB_INVOICE

2. There are already enchancement points avialable in RVADIN01. You can also make a copy of this program if needed.

3. In NACE make sure you mainatin Program Name e.g ZRVADIN01 Form Routine "Entry" and your Form Name.

4. You can also avoid making Z driver program and call subroutine from your script to fetch additional data you want.

Check How to Call Subroutine in Sap Script:-

http://wiki.sdn.sap.com/wiki/display/ABAP/SubroutinesAndTheirUseIn+SAPScript

Edited by: Vinit Joshi on Mar 9, 2012 11:27 AM