cancel
Showing results for 
Search instead for 
Did you mean: 

Adobe SFP Processing HEADERTEXT Data in Clone of ZMEDRUCK_PO_PDF

Former Member
0 Kudos

I cloned ZMEDRUCK_PO_PDF and would like to process HEADERTEXT data so it is printed in table format. Our goal is to have the HEADERTEXT print in a variable size subform so if there are only 3 lines of text we have a box of data which only takes up space for 3 lines on the PO form. And if we have i.e. 10 lines of text the box can expand to accomodate 10 lines of data. I've move the HEADERTEXT to print below header data and above item data.

At this time it is printing in a fixed format. Any ideas on how to resolve this?

Regards,

Helen

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

I thought this was resolved but it really isn't. When calling Functional Mod READ_TEXT I need to pass the PO Number EBELN but I can't get that value in the CODE INITIALIZATION. With testing I can force a constant into that field but when I try to access that value as a variable I'm not getting it.

Does anyone know how I can access the value in field EBELN in the CODE INITIALIZATION for PDF form which is a clone of ZMEDRUCK_PO_PDF?

Regards!

Former Member
0 Kudos

In case anyone is doing the same processing I resolved my issue by using field HEADER-EBELN.

Former Member
0 Kudos

Problem solved. I used the CODE INITIALIZATION in the interface to generate the table I needed. If anyone is interested I added code in the CODE INITIALIZATION which used Funtion Mod READ_TEXT to retrieve the data. In the CODE INITIALIZATION I added an INPUT field PO NUMBER (EBELN) and output table i_POTEXT. Then in the GLOBAL area I added the table i_POTEXT.

Code for FM READ_TEXT

CALL FUNCTION 'READ_TEXT'

EXPORTING

id = 'F01'

language = 'E'

name = EBELN

object = 'EKKO'

TABLES

lines = i_result

EXCEPTIONS

OTHERS = 8.

Then LOOP through i_result to move the data into i_POTEXT.

Former Member
0 Kudos

I have that checked off and it doesn't help. For example In the HEADERTEXT in the PO I have 10 lines of text. If I shrink the box down on my form I can only see about 2-3 lines of text. If I expand the box I see all 10 lines of text plus additional room. This leads me to believe each line of text if not being treated as a row in a table. I want each row in the HEADERTEXT table to be treated as an individual entry on the form so the box on the from expands depending on how much room is needed to present the data.

Helen

Former Member
0 Kudos

I've been looking around and it appears perhaps I should be using FM READ_TEXT then put the individual lines into a table for processing in form. Anyone one have any thoughts on this idea?

Helen

Former Member
0 Kudos

Hi Helen,

I think you should be able to do it using READ_TEXT FM.

it return a table parameter which contains 2 fields format and tdline.

You can create the table with one field tdline in your form and make it as flowed. so it you get no. of rows

and in the properties you can remove the borders. so that it gives look of one text field and nota table if thats what you are looking for.

Former Member
0 Kudos

I got the FM READ_TEXT to write individual lines of text in a table now I'm having a tough time getting that data to print in the form. I tried lots and lots of scenarios. What is the approach for getting the data in the form? For example, in the interface in the section CODE INITIALIZATION should I get the data using FM READ_TEXT then how would I pass the table to the form? At that point is it an IMPORT?

Any guidence would be greatly appreciated.

Helen

Former Member
0 Kudos

Hi,

You can create your text field the same way you are doing now.

and just check the check box ALLOW MULTIPLE LINES in properties.