Smartforms - printing header text for a PO
Hi,
I need to print the header text from a PO. To do this I'm using the function Module READ_TEXT.
While entering the header text if they make it bold or underlined then the Output is having html tags. How to get rid of these tags?? (Ex: <B> Header Text </>)
Thank you,
Renu
Use REPLACE or TRANSLATE to replace the tags with spaces or to just remove them, i.e. "replace with nothing" (not sure about this option though - never tried it myself). You might need to do SHIFT or CONDENSE afterwards to get rid of extra spaces, if necesary.
Similar Messages
-
How to use Read_text in Smart Forms for printing Header Texts
Dear ALL,
I want to print Header Texts in SmartForms, For that
I am using T/Code VL02N .. and choosed Header ..
got this details... from Text Header.
Text Name :0080000441
Language :EN
Text ID :Z002
Text Object :VBBK.
So in Smart forms Under Template i have created a text and Program Code .
Inside that I have used this below code .
CALL FUNCTION 'READ_TEXT'
EXPORTING
*CLIENT= SY-MANDT
ID = 'Z002'
LANGUAGE = SY-LANGU
NAME = NAME
OBJECT = 'VBBK'
TABLES
LINES = IT_TLINE
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
NOT_FOUND = 4
OBJECT = 5
REFERENCE_CHECK = 6
WRONG_ACCESS_TO_ARCHIVE = 7
OTHERS = 8.
IF SY-SUBRC 0.
CLEAR IT_TLINE.
ENDIF.
Kindly suggest me, Where to declare the variables and loops for using this Read_Text Syntax in Smartforms .
Response to this will be highly appreciated........
Regards ,
Vinoth.hi
good
please check this code
CONSTANTS:
*For text reading like in LCNMMFTX / FORM SET_CONTROL_TEXT
text_id like thead-tdid value 'MATK',
text_obj like thead-tdobject value 'AUFK '.
data tlines like tline occurs 0 with header line.
data tdname like thead-tdname.
data tdheader like thead.
if not it_proj-ltxsp is initial.
refresh tlines.
tdname = sy-mandt.
tdname+3 = it_proj-rsnum.
tdname+13 = it_proj-rspos.
tdname+17 = it_proj-rsart.
call function 'READ_TEXT'
exporting
id = text_id
language = it_proj-ltxsp
name = tdname
object = text_obj
importing
header = tdheader
tables
lines = tlines.
exceptions
not_found = 01.
thanks
mrutyun^ -
hi,
when i went through smart form code ,i found the following code for printing texts for items(me23n-->item--
>texts)
in TEXT node in smartform (for printing item text):
TYPE: INCLUDE TEXT
TEXT NAME : &G_TEXT_KEY&
TEXT OBJECT: EKPO
TEXT ID: F01
LANGUAGE: &SY-LANGU&
How to create text name,text object,text id?
when i gave text name & text id in SO10 &then display it's giving message Text Id F01 for Text Object TEXT does not exist.
how to create text object EKPO instead of TEXT.where can i see this TEXT OBJECT option.
how can i print header texts in ME23N?
please help?hi mustafa,
1. If you want to create text name, text object, text id.. you have to create functionally in spro settings....
spro
> mm
> purchasing
> messages
> texts for messages
> define texts for purchase order
here you can define header texts or item text functionally
If you want to create in you po then go to header text tab and create with respective text
2. if you want to print header texts simply pass only
po number in text_name,
text_object : ekko
text_id : depends up on ur text check i header text tab
language key u know as usual
Don't forget to reward points
praveen -
Adobe Forms: Printing Header Text - Background as Dark
Hi,
We are upgrading our ECC system to Enahncement Pack 5.
We have Adobe forms for Sales Order, Delivery Notes,... In Border Palatte, we have set 'Solid' as a background fill for our header texts
After applying patches, Adobe forms started printing header texts background very Dark.We are not able to read the texts. If I view the document in the spool then they are displayed correctly. If I save spool document on the desktop and print it then also output is printed as we want. Only when we print it directly through VA01, VA02 ( directly from SAP ) then it gives this error.
I removed the background fill then it prints text correctly but then I loose the separation between header and content.
I will appreciate any help in this regard
Jitendra Pongurlekar
Moderator message: wrong forum, please have a look in the forum for "Adobe Interactive Forms".
Edited by: Thomas Zloch on Mar 4, 2011 10:55 AMHi mrudul,
as usual in programming, you got different ways to solve the problem. So if you work through the content here on SCN you will find a lot of examples how to decide between different letter heads. The easiest solution (and might be the best) is to pass the necessary data via the interface and do not add any condition in the form itself.
How to create a dynamic field and all the stuff is very basic knowledge, so I think you do not need any explaination how to do that. If so I refer you to the official documentation provided by SAP.
If you have some minutes please work through this blog Before You Ask - Just another guide and phrases like "urgent" or "do reply" are just not necessary to get an answer
~Florian -
How can i add Document Header Text for s_alr_87012357
Hi Gurus
How can i add Document Header Text for s_alr_87012357(Advance Return for Tax on Sales/Purchases).do i need change the standard program or is there any alternate to do this please help me out.i found it .its in output list and i did change the layout settings.thanks
-
Dear colleagues,
I have created a new header text for PR under object EBANH (as Z01) from transaction code SE75. This new header text appears when creating/changing PR but when I fill this new header text right behind saving of PR filled data disappears from this new header text of PR.
Can you please advice how to solve this issue?
Thanks.Hi Nick,
EBANH is active if it wouldn't have than I couldn't maintain the original text area (B01) supplied by SAP. But I can simply maintain and save original header note of PR.
Thanks.
PS. Where can I see if EBANH is active or not? -
Hello,
Mine client requirement is like they want default header Text for all PO.Please guide me, what is the customization required?
Regards,
JyotiHi jyoti,
As per my understanding of your requirement, you can try to maintain the default PO Text in the "Vendor Master Record" or in "Contract" if applicable and then you need to do the following customisation to adopt these texts in the Purchase Orders.
IMG -> Material Management -> Purchasing -> Purchase Order -> Texts for Purchase Orders -> Define Text Types for Header Texts and Define Copying Rules for Header Texts.
In Define Copuying Rules for Header Texts -tab you can maintain that in which Target Header Text, the deault PO text should be adopted and from where i.e. From Vendor Master Record or Contract or RFQ. Check which of this satisfy your requiremnt to the maximum extent.
Please check this and see if your requirement is fulfilled or not.
Regards,
Ankit
Edited by: Ankit Patodi on Jan 12, 2011 11:55 AM -
Header text for delivery order
Hi,
I want to retreive the header text for the given delivery number. Can anyone explain me in detail way how to retreive this.
If there is any FM please let me know What inputs should be given to that FM.
Thanks,
Rose.Hi,
You can use the FM read_text.
see the link below to solve your purpose.
http://www.blogtoplist.com/rss/function.html
Please reward points if useful.
Regards
Rose -
Header Text for Field Catalog ALV Grid doubt ..
Hi everybody
I have an ALV Grid List Report (REUSE_ALV_LIST_DISPLAY)
but i have a trouble: the header texts for the fields are always truncated to 10 positions.
The code for fill the Field Catalog are:
CLEAR l_field_cat.
l_field_cat-COL_POS = 2.
l_field_cat-FIELDNAME = 'AVERAGE'.
l_field_cat-TABNAME = 'T_REPORT'.
l_field_cat-REF_TABNAME = 'RPSCO'.
l_field_cat-REF_FIELDNAME = 'WLP00'.
l_field_cat-SELTEXT_S = TEXT-004. <- 'AverageAmount' 20 lenght
l_field_cat-DDICTXT = 'S'.
l_field_cat-KEY = ' '.
l_field_cat-KEY_SEL = ' '.
APPEND l_field_cat TO p_field_cat.
But, although the column appears with 20 characters lenght, the header text appears 'AverageAmo', and it is in the same way for all the fields, even with fields with 40 characters lenght.
What am i doing incorrect ?
Thanks in Advanced
FrankThat is because of field I_field_cat-SELTEXT_S.
This will always display 10 char long text.
To avoid truncating you can specify length for the header.
Try this
x_fieldcat-seltext_l = TEXT-004.
x_fieldcat-outputlen = 20.
x_fieldcat-ddictxt = c_l.
Message was edited by: Ashish Gundawar
Message was edited by: Ashish Gundawar -
How to retrieve the header texts for a contract
HI,
i think we need to use the FM read_text to get the header texts for a contract but dont know how to use the FM like what all the parameters are passed to that to get the header texts of a contract(va43).
any help is appreciated with points.
thanks
prasadHi,
Pls refer this code,
CALL FUNCTION 'READ_TEXT'
EXPORTING
client = sy-mandt
id = '0001'
language = sy-langu
name = v_textid
object = 'KNMT'
IMPORTING
header = t_header
TABLES
lines = t_lines
EXCEPTIONS
id = 1
language = 2
name = 3
not_found = 4
object = 5
reference_check = 6
wrong_access_to_archive = 7
OTHERS = 8.
IF sy-subrc EQ 0.
LOOP AT t_lines.
CONCATENATE w_arktx t_lines-tdline INTO w_arktx
SEPARATED BY space.
ENDLOOP.
ENDIF.
IF w_arktx NE space.
MOVE w_arktx+1(1583) TO t_lips-arktx.
ELSEIF w_arktx EQ space.
CLEAR w_text_name.
CLEAR v_textid.
wa_lips-matnr = t_lips-matnr.
wa_lips-vkorg = t_likp-vkorg.
wa_lips-vtweg = t_lips-vtweg.
w_text_name = wa_lips.
CLEAR w_arktx.
Retrieval of Sales Text
CALL FUNCTION 'READ_TEXT'
EXPORTING
client = sy-mandt
id = '0001'
language = sy-langu
name = w_text_name
object = 'MVKE'
IMPORTING
header = t_header
TABLES
lines = t_lines
EXCEPTIONS
id = 1
language = 2
name = 3
not_found = 4
object = 5
reference_check = 6
wrong_access_to_archive = 7
OTHERS = 8.
IF sy-subrc EQ 0.
LOOP AT t_lines.
CONCATENATE w_arktx t_lines-tdline INTO w_arktx
SEPARATED BY space.
ENDLOOP.
ENDIF.
IF w_arktx NE space.
MOVE w_arktx+1(1583) TO t_lips-arktx.
ELSE.
REgards
srinivas -
Printing Header Text in Purchase Order
HI,
Actually I had the problem. A smart form has been developed for printing Purchase Order. Here in smartform a field has been declared to accept whatever the text had keyin in Header Text has to appear in Purchase Order. It is printing correctly until it is of Two paragraphs which consists of two or max three lines. Whenever it is exceeding these two paragraphs even a single word. It is printing something from the middle and in a reverse way. To get the clear picture I will give the example below.
<b>Ex.</b> <b>I</b>) This Purchase Order has been given.
Delivery has to be make on time.
In the above example it is ok printing properly.
<b>Ex.</b> <b>II</b>) This Purchase Order has been given after
verification.
Delivery has to be make on time as scheduled.
On Delay PO will be cancelled.
In this IInd example the output is showing as
<b>Output:</b> to be make on time as scheduled.
verification.
This Purchase Order has been given after
On Delay PO will be cancelled
Delivery has
Waiting for your help.
Thanks in Advance.
bye
Abdul Mannanhi,
Ofcourse, the field is a part of main window in Smart Forms. I will elaborate further, In Main window we declared one <u><b>Table</b></u> in the Tables <u><b>Main Area</b></u> there is a <u><b>Row</b></u> and in a Row there is a <u><b>Cell</b></u> in a cell we declared one <u><b>Text Field</b></u> which is taking that <u><b>header text</b></u> and printing it as output.
I hope you got it.
Waiting for reply with a good solution.
Thanks and Regards.
Bye.
Abdul Mannan -
Smartforms : print standard texts or texts out of document with command in.
We used to have an output via Sapscript (printout of a purchase order) and the output was containing standard texts or text out of the purchase order, which contains commands (a test in the standard text or an include of another standard text). This text was correctly printed via sapsript, command were taken into account.
Now we have a new output for the purchase order which is working with smartforms. When working in the smartforms with a text type 'include text', commands in the text are not working.
When working with smartforms, is it not possible to include texts (out of the STXH table) which contains commands? These commands are not taken into account.
Thanks.Thanks for the answers!
Example how they work here : in the material master, purchasing text => somtimes include of a 'standard' text. This to avoid typing the text in all materials which use this text. We can avoid this by instead of including the text, to 'append' the standard text.
Also in some standard texts, some tests were done (on output type, purchasing organisation,.....) which we can change by reading the text in the print program and building those tests in the print program itself.
I just wanted to be sure that there was a possibility or not in Smartforms to work like that because we worked like this using sapscripts and it worked fine.
We will change this way of working and build the logic into the print program. We will inform the master data team not to use the 'include' command into a material master text but instead append the standard text directly into the material master text.
Best regards,
Ann. -
Help required. How to print Header Text in customized PO ?
Hi experts,
Please help me go forward with this.
I'm using a ZMEDRUCK & standard printing program.
I have put my code here. Pls go through it and help me what has to be corrected here.
PROGRAM ZMEDRUCK_SUBP2.
FORM fetch_table_data TABLES in_tab STRUCTURE itcsy
out_tab STRUCTURE itcsy.
TABLES EKKO.
DATA: BEGIN OF header OCCURS 0,
ld_txt1(163),
ld_txt2(163),
ld_txt3(163),
END OF header.
DATA: li_lines LIKE STANDARD TABLE OF tline WITH HEADER LINE,
ID like THEAD-TDID,
TNAME LIKE THEAD-TDNAME,
TDOBJECT like THEAD-TDOBJECT.
DATA HTEXT LIKE EKKO-EBELN.
DATA f_lines TYPE P.
* HTEXT = EKKO-EBELN.
READ TABLE in_tab WITH KEY EKKO-EBELN.
if sy-subrc = 0.
TNAME = in_tab-value.
ENDIF.
*TNAME = EKKO-EBELN.
*CONCATENATE EKPO-ebeln EKPO-ebelp INTO v_item_text.
*MOVE v_head_text to HNAME.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = TNAME
IMPORTING
OUTPUT = TNAME
CALL FUNCTION 'READ_TEXT'
EXPORTING
* CLIENT = SY-MANDT
id = 'F01'
language = 'E'
name = TNAME
object = 'EKKO'
* ARCHIVE_HANDLE = 0
* LOCAL_CAT = ' '
* IMPORTING
* HEADER = TNAME
tables
lines = li_lines
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
NOT_FOUND = 4
OBJECT = 5
REFERENCE_CHECK = 6
* WRONG_ACCESS_TO_ARCHIVE = 7
* OTHERS = 8
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
READ TABLE li_lines INDEX 1.
IF sy-subrc = 0.
header-ld_txt1 = li_lines-tdline.
ENDIF.
DESCRIBE TABLE li_lines LINES f_lines.
data: lstr type String,
lstr1 type string,
lstr2 type string,
lstr3 type string,
lstr4 type string.
read table li_lines index 1.
lstr = li_lines.
condense lstr.
clear li_lines.
read table li_lines index 2.
lstr1 = li_lines.
condense lstr.
clear li_lines.
read table li_lines index 3.
lstr2 = li_lines.
condense lstr.
clear li_lines.
if f_lines GT 3.
read table li_lines index 4.
lstr3 = li_lines.
condense lstr.
clear li_lines.
read table li_lines index 5.
lstr4 = li_lines.
condense lstr.
clear li_lines.
endif.
DATA: v_text type text.
CONCATENATE lstr1 lstr2 lstr3 lstr4 into v_text separated by ' '.
CLEAR out_tab.
READ TABLE out_tab WITH KEY name = 'TNAME'.
out_tab-value = v_text.
MODIFY out_tab INDEX sy-tabix.
ENDFORM.
And my script is :
/:PERFORM FETCH_TABLE_DATA IN PROGRAM ZMEDRUCK_SUBP2
/:USING &EKKO-EBELN&
/:CHANGING &TNAME&
/: ENDPERFORM
IL RECEIVED FROM M/S &TNAME&Hi,
Use this Function module 'READ_TEXT'
T_lines contains the header text, you can loop it and display it in sap script
Function module to read the header text
CALL FUNCTION 'READ_TEXT'
EXPORTING
client = sy-mandt
id = 'F01'
language = sy-langu
name = ekko-ebeln
object = ekko
TABLES
lines = t_lines
EXCEPTIONS
id = 1
language = 2
name = 3
not_found = 4
object = 5
reference_check = 6
wrong_access_to_archive = 7
OTHERS = 8.
Regards
Krishna -
How to Print Header text in PO SAPScript
Hi Gurus,
I am working on PO Script (MEDRUCK). I copied the Standard to a Z form. ZMM_MEDRUCK, Now I need to print the the Header text at the end of MAIN window. I created a a perform and call it from the Script and read the heder text by using FM Read_text
DEFINE &TEXT1& = ' '
PERFORM GET_TERMS IN PROGRAM ZMM_MEDRUCK_ROUTINE
USING &EKKO-EBELN&
CHANGING &TEXT1&
ENDPERFORM
PROTECT
&TEXT1&
ENDPROTECT
but while returning I am getting only one line. Can any body suggest me how I can read the Header text in PO script. Please provide the sample Code.
Regards
SonyHi,
Use this Function module 'READ_TEXT'
T_lines contains the header text, you can loop it and display it in sap script
Function module to read the header text
CALL FUNCTION 'READ_TEXT'
EXPORTING
client = sy-mandt
id = 'F01'
language = sy-langu
name = ekko-ebeln
object = ekko
TABLES
lines = t_lines
EXCEPTIONS
id = 1
language = 2
name = 3
not_found = 4
object = 5
reference_check = 6
wrong_access_to_archive = 7
OTHERS = 8.
Regards
Krishna -
Header Text for Purchase Requisition
Problem Description: Is there a way Header text can be configured / customized for purcahse requisitions just as we do for POs and then defined to be copied to purchase order?
I know Header Note is available on Pur Req but comments in this section remain internal.
I have also reseached that there is a BADI 'Adopt Header Text When Copying Purchase Requisitions' but in standard system this is not active.Hi,
try this BADI - ME_REQ_HEADER_TEXT : Header Text: Enjoy Purchase Requisition
Maybe you are looking for
-
How to backup one Time Capsule with another Time Capsule?
I have two Time Capsules and a Mac Mini. The first Time Capsule (TC1) is plugged by ethernet cable directly to my Mac Mini. It is also set up to provide my home with a wireless network. The second Time Capsule (TC2) is upstairs and connected to this
-
Change header pricing condition in sales order
Hi, I have an requirement in VA01 and VA02 to automatically edit one header pricing condition. The user can able to change the value of that condition type in header not in items . Does anyone know what user exit I can use for this requirement. Thank
-
I am new to Java. I recently ran into a need to have a Java print queue manager to handle network printers. Is something like this already available or are there companies who can provide this? Please email me with any comments ([email protected]). T
-
2010 Macbook Pro Vs 2014 Macbook Air
Hi, I currently have a 13in 2010 Macbook Pro with 8gb ram and a 256hd. I use it for editing little videos using Final Cut Pro, and editing photos on CS5. I'm wondering if my 2010 MBP is better than a 13in MBA 2014. Will a MBA be able to handle the sa
-
About STORAGE_PARAMETERS_WRONG_SET
Hi Experts , When i execute ke24 the system popup the error message : <b>Runtime errors STORAGE_PARAMETERS_WRONG_SET Occurred on 07/25/2007 at 17:32:11 &INCLUDE INCL_INSTALLATION_ERROR What happened? The current program had to be