Script SD Form
Hi experts,
how can i get the header texts from sales order into our out put of script form,is there ant table and fields or any function module is there,if there how can i use...
for example: Text (_Final Destination)_ is there in header texts of sales order(va02), i want print the text what ever i given the text in FInaldestination to my form.
could any body help me..
thanks,
Hi,
Use read_text fm
The long texts of a document are stored in a encrypted format in the STXH and STXL tables, where STXH stores the header information of the long text like TDOBJECT, which indicates which text object the long text belongs to, TDID which indicates the Text ID and TDNAME which is the actual name of the long text.
As these texts are stored in a encrypted format, the text cannot be read using a SELECT statement. You will have to use the function READ_TEXT. The easiest way of getting to know the parameter values is to go to a document, open the long text in a full screen mode. For example, when you wan to see the long text for a Purchase order, go to transaction ME23n. Assume, you want to see the parameters for the Header Text. In the first Tab Strip Control, click on the Texts tab and select the Header Text node on the left hand side, which will display the text on the right hand side. Now, double click on the text editor on the right hand side. This will open the text in the full screen mode. In the menu Go To --> Header, you should be able to see the values for all the three parameters we discussed above. We will have to do the same thing for whichever text parameters we want to see.
CALL FUNCTION 'READ_TEXT'
EXPORTING
CLIENT = SY-MANDT
ID =
LANGUAGE =
NAME =
OBJECT =
ARCHIVE_HANDLE = 0
LOCAL_CAT = ' '
IMPORTING
HEADER =
TABLES
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.
Regards
Similar Messages
-
URGENT- Need advice on executing scripts from Forms 6i
Hi all,
Quick background info:
I'm working on a conversion project from Forms 4.5 client/server applications to a three tier, web based Forms 6i environment.
We're running Oracle 8i DB on HP-UX machines, Oracle 9ias on HP-UX machines, and users access forms through Netscape
on Win2000 platform.
The problem:
I have a SQL execution interface form from which users have been able to run dynamic SQL scripts w/o having direct access to
a SQL Plus prompt (uses the 'HOST' command in 4.5). How can this functionality be implemented in the three tier environment?
Unless other options are available, my plan is to use a Java servlet to access the 8i database on the UNIX box and display
output on an html page. Is there a better/easier way?!
Any advice is appreciated...
FLM
Paychex, Inc.Thanks for the response,
I may be able to invoke the script from Forms using the HOST command, but how is the script output
displayed back to the browser?
FLM
[email protected]
You can probably still use the host to sqlplus, but this time it will run on the Forms Server.
You just need to make sure that the dynamic SQL files are uniquly identified for each customer. -
Sap script - using form-endform
I have used follwing code in subroutine,but in quality control this is rejected because of "structure" keyword.
FORM GET_TKNUM TABLES CT_INTAB structure ITCSY
CT_OUTTAB structure ITCSY.
IF CT_INTAB[] IS NOT INITIAL.
LOOP AT CT_INTAB INTO LV_INTAB.
READ TABLE CT_INTAB INDEX 1.
CHECK SY-SUBRC = 0.
MOVE ct_INTAB-VALUE TO LV_REQNO.
CLEAR CT_INTAB.
ENDLOOP.
ENDIF.
Then i used following code but values are not coming from script.
FORM SHIP_INFO USING CT_INTAB TYPE TABLE ITCSY
CT_OUTTAB TYPE TABLE ITCSY.
IF CT_INTAB[] IS NOT INITIAL.
LOOP AT CT_INTAB INTO LV_INTAB.
READ TABLE CT_INTAB INTO LV_INTAB INDEX 1.
CHECK SY-SUBRC = 0.
MOVE LV_INTAB-VALUE TO LV_SHIPNO.
CLEAR LV_INTAB.
ENDLOOP.
ENDIF.
what is another way to define form?Try using 'LIKE'.
LOOP AT CT_INTAB INTO LV_INTAB.
ENDLOOP.
FORM GET_TKNUM TABLES CT_INTAB LIKE ITCSY[]
CT_OUTTAB LIKE ITCSY[].
IF CT_INTAB[] IS NOT INITIAL.
READ TABLE CT_INTAB INDEX 1.
CHECK SY-SUBRC = 0.
MOVE CT_INTAB-VALUE TO LV_REQNO.
CLEAR CT_INTAB.
ENDIF.
ENDFORM
You may also refer to the below sample code from ABAP HELP. (I could not find a hyper link to it though)
TYPES: BEGIN OF FLIGHT_STRUC,
FLCARRID LIKE SFLIGHT-CARRID,
PRICE LIKE SFLIGHT-FLDATE,
END OF FLIGHT_STRUC.
DATA: MY_FLIGHT TYPE TABLE OF FLIGHT_STRUC,
IBOOK1 TYPE TABLE OF SBOOK,
IBOOK2 LIKE TABLE OF IBOOK1,
STRUC TYPE SBOOK.
PERFORM DISPLAY USING MY_FLIGHT IBOOK1 IBOOK2 STRUC.
FORM DISPLAY USING P_ITAB LIKE MY_FLIGHT[]
P_BOOK1 LIKE IBOOK1[]
P_BOOK2 LIKE IBOOK2[]
P_STRU LIKE STRUC.
DATA: L_FLIGHT LIKE LINE OF P_ITAB,
L_CARRID LIKE L_FLIGHT-FLCARRID.
WRITE: / P_STRU-CARRID, P_STRU-CONNID.
LOOP AT P_ITAB INTO L_FLIGHT WHERE FLCARRID = L_CARRID.
ENDLOOP.
ENDFORM. -
Getting windows error during running the sql scripts from form 6i
I made a little form application. The purpose of this application is to generate explain plan for a particular SQL. Some sql scripts run internally in order to populate the result on forms screen after pressing the forms button but I am getting windows error during running the sql scripts from form 6i.
I am using forms 6i with patch 17 with Oracle 10G database on windows 2000 professional on same computer.
This application runs fine with 8i.
Please inform me where the problem is and how to overcome it.
Zafri.I am using Text_IO in my form's when button press trigger , inorder to create the
text file, then in the same when button press triger
I am calling RMAN via host command in order to run the script which was created by text_IO.
Below you find some of the code. I will appreciate if you solve the problem.
when button press trigger:
Declare
in_file3 Text_IO.File_Type;
linebuf3 VARCHAR2(1800);
output11 varchar2(1000);
BEGIN
output11:='C:\EXPLAIN_PLUS\misc\rm_file.bat ';
Host(output11,no_screen);
:sql.execution_plan:= 'Working........................';
synchronize;
in_file3 := Text_IO.Fopen('c:\explain_plus\misc\create_table.txt', 'w');
Text_IO.Put_Line(in_file3, linebuf3);
Text_IO.put_line(in_file3,' ');
Text_IO.put_line(in_file3,' run { sql "create table PLAN_TABLE (statement_id,...object_name varchar2(30),object_instance numeric,object_type varchar2(30),optimizer varchar2(255),search_columns number,id .....partition_start varchar2(255),partition_stop varchar2(255),partition_id numeric,other long,distribution varchar2(30)) "; } ');
Text_IO.put_line(in_file3,' ');
Text_IO.put_line(in_file3,' ');
Text_IO.FCLOSE(in_file3)
Declare
un VARCHAR2(80);
pw VARCHAR2(80);
cn VARCHAR2(80);
output VARCHAR2(1000);
output2 VARCHAR2(1000);
dummy varchar2(40);
in_file Text_IO.File_Type;
linebuf VARCHAR2(1800);
BEGIN
Get_Connect_Info(un,pw,cn);
/* for Plan_table Begg. Second INNER BLOCK */
declare
dummy2 varchar2(40);
begin
select table_name into dummy2 from all_tables where table_name='PLAN_TABLE';
if dummy2 = 'PLAN_TABLE' then
output2:='rman target/ nocatalog @C:\EXPLAIN_PLUS\MISC\TRUNC2.txt ' ;
Host(output2,no_screen);
end if;
exception
when no_data_found then
output2:='rman target/ nocatalog @C:\EXPLAIN_PLUS\misc\create_table.txt ';
Host(output2,no_screen);
end; -- -
Satndard SAP script or form name to generate FI invoice
Plz let me know if u know the standard SAP script or form name to generate the FI invoice.
Regards
Nivetha.Hi,
I guess the terminology's causing some problems. Here's what I think you need to do;
In transaction V/30 select the Output Type then double-click on the folder 'Processing Routines'. The columns are as follows;
Medium - Print, email etc
Program - Name of the print program
FORM Routine - name of the subroutine in the print program that will be called
Form - Name of the SAPscript (if used)
PDF/Smartform Form - Name of the Smartform, or pdf form (if used)
Type - If a Smartform or pdf form is specified, select from this drop-down which type it is.
If you're getting an error when you enter your parameters, it would be useful if you told us what the error was.
Regards,
Nick -
Scripting for Form Guides in ES2?
Hi,
I started developing guides in ES2 and able to genarate the some examples successfully.
I am able to pre populate the data into Forms.
But I paused writing the script for form guides. Please let me know good material for scripting the form guides in ES2.
And more thing is how to draw static Table (normal table) on the form guides ?
Thanks
PraveenI'm not aware of any tutorial. The documentation team has not created one, but there is an overview video here:
http://my.adobe.acrobat.com/lces2fsp_guide_based_applications/
The help on how to create guides is here:
http://help.adobe.com/en_US/livecycle/9.0/workbenchHelp/003610.html
How to use a guide in a process is documented in the Creating Human-Centric Process section of the Workbench ES2 help:
http://help.adobe.com/en_US/livecycle/9.0/workbenchHelp/000217.html
Scott -
Sending emails in PDF & TXT format generated by SAP script/Smart forms
Hi
We have a requirement to configure SMTP node to send emails in PDF & TXT format. Currently, Output format for SAP Documents generated by SAP Script/Smart Forms configured in PDF. (Tx - SCOT - SMTP Node - Intetnet - Output Forms for SAP Documents). But, We also like to send emails in TXT format for other application in the same system. I see that you can send emails generated by SAP Script/Smart Forms either in PDF or TXT format not both.
Is it possible to send the emails in both the formats by configuring in Tx SCOT?
Your inputs will be appreciated.
Regards
ChanduHi chandu,
1. emails in both the formats by configuring in Tx SCOT ?
Scot will allow only ONE AT A TIME.
2. The other workaround is,
that using some FM
convert the OTF (sapscript/smartform)
data to TEXT,
and send it as RAW
3. Configure RAW = TEXT in scot.
regards,
amit m. -
Script or form for a transaction
Hi,
How would you identify if script or form would work with a transaction. I am currently working with sub contracting challan. I assigned my custom driver program and form name in NACE. When i execute the transaction J1IF01 , i am able to view my form layout but the values are not getting populated. When i checked in debugging mode in driver program NAST entries are not filled.
But if i change the driver program to J_1I57FPN and use script - J_1I_57F4 instead of smartform , transaction entries are correctly flowing.
Can some one help me to identify if this is just a problem with output type configuration or if script is to be used ?
ThanksWhat you can do is find out what is used with standard transaction smartform or sapscript.
Go to se93 enter the transaction code and find out the name of the program.
Now go to se11, open table TNAPR, put program name in pgnam field and you get the form name in fonam.
Regards,
Lalit Mohan Gupta. -
AV Scripts, Free form docs, Breakdown reports and more...
Hi there,
We've posted an update to Adobe Story that includes exciting features like AV Scripts, Free form documents, and Breakdown reports among other things.
Check out the latest release notes to know more.
- Adobe Story teamThis is a very very nice update, especially all the breakdown reports that I was missing badly.
-
Run SQLPlus script from Forms 10g
Hellou.
In Forms 10g I am generating sql script which need to be run under sqlplus. It contains some selects and thay are spooled into file (It need to be like this) But generating this script is in the form and I need althoug call this script from form.
So my question is> How can I call sqlplus commands uder forms 10g?? For exmaple like this:
sqlplus: @ Report.sql or other??
Thanks ZoffobHello,
If you know the syntax used on the DOS command line, put it "as is" in a Webutil Client_Host() built-in (see the documentation)
Francois -
In SAP Script the form is not printing in required format
hi
in my sap script i am facing a issue. when i trigger the output on the screen, first page is coming correctly but second page has mixed up the alignment, i want to say the footer is coming up and main window box has gone sb total window shift to left while it should be right.
regards
atulHey Mishra,
Check in the page 2 Layout in your scrit form. The layout what you created for second page allighment is not correct. It seems you need to change the the footer and main in all the pages. Goto Page Windows -> Select the Seond page Name -> and check the layout ( Setting -> Form Painter).
Regards,
Saravanan M -
Script for Form validator in head causes error
When I use the Window/Behaveiors/ to create a form validator, Dreamweaver CS5 puts script in the Head of page, and seems to work ok. But when I validate page with W3c it says there are errors with code and as Dreamweaver created this I have no idea what to do to put right, so could someone please help. This is code generated by Dreamweaver, all other pages have past with flying colors!
<script type="text/javascript">
function MM_validateForm() { //v4.0
if (document.getElementById){
var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=document.getElementById(args[i]);
if (val) { nm=val.name; if ((val=val.value)!="") {
if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
if (p<1 || p==(val.length-1)) errors+='- '+nm+' must contain an e-mail address.\n';
} else if (test!='R') { num = parseFloat(val);
if (isNaN(val)) errors+='- '+nm+' must contain a number.\n';
if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
min=test.substring(8,p); max=test.substring(p+1);
if (num<min || max<num) errors+='- '+nm+' must contain a number between '+min+' and '+max+'.\n';
} } } else if (test.charAt(0) == 'R') errors += '- '+nm+' is required.\n'; }
} if (errors) alert('The following error(s) occurred:\n'+errors);
document.MM_returnValue = (errors == '');
</script>If the script is working fine in all browsers, you could put it in an external JS file and link to it, then the W3C validator won't find an error.
If you don't know already, learn about how to do this:
http://www.hypergurl.com/jsfiles.html -
How to restrict Order types KA and AB in script output form
How to restrict KA AND AB order types in script output data is coming from bkpf-blart .
program is rfkord10.
and form is f140_acc_stat_1
in script output i dont want to display KA AND AB order types ..
data is coming from standard report.
i copied form into zform.
in output it is displaing all order types ..
is there any solution to restrict above order types.Hi
Check the data structures used in the script
Since it is account statement of customer it uses the Tables BSID and BSAD in which the field BLART field is there whose values are KA and AB
check for the structures which are used in the script and in them search for the field BLART in Se11 and accordingly keep the condition
It will work
Regards
Anji -
Problems in sap script/smart forms
what are the major problems will come in real time about smart form and sap script?
Hi there.
Question 1:
Use font MICR_C for MICR CMC-7 or MICR_E for MICR E-13B
http://help.sap.com/saphelp_nw04/helpdata/en/90/78f078030211d399b90000e83dd9fc/frameset.htm
Question 2:
/: SET DATE MASK = 'DDMMYYYY'
http://help.sap.com/saphelp_nw04/helpdata/en/d1/8034d4454211d189710000e8322d00/frameset.htm
Question 3:
/E BOX_ELEMENT
/: POSITION WINDOW
/: POSITION YORIGIN &Y& LN
/: SIZE HEIGHT &HEIGHT& LN
/: BOX FRAME 10 TW
/: BOX XPOS '0.0' CM WIDTH 0 TW FRAME 10 TW
Question 4:
&symbol(C)&
http://help.sap.com/saphelp_nw04/helpdata/en/d1/8034d4454211d189710000e8322d00/frameset.htm
Question 5:
See SAP Note 129581.
Best regards.
Valter Oliveira.
Edited by: Valter Oliveira on May 30, 2008 4:42 PM -
Hi, I have been given the program name. How do I find out which form/script is attached to that program?
Hi,
Using the NACE trasaction code you come to know which form and the Drier Program is used, first select the application type in NACE then Press the Output Types, you need to know the Output type then Select the output type then press the Processing Routines then you will get the Program name and the Layout nmae
and also, Look at the table TNAPR to know the Layout name
Regards
Sudheer -
Hi All,
How to find out in a particular object whether SAP scripts or smart forms are used?
If forms are used is there any t.code to find out which type of form is used?
Regards,
Vamsi PHello Vamsi,
<b>SAP scripts and SMARTFORMS - both serve the same purpose.</b>
SMARTFORMS were introduced since the release of SAP 4.7. Earlier to that it was only SAP scripts for designing layouts. SMARTFORMS have few additional benefits in terms designing over scripts.
Now, coming to your questions - Every Script or a SMARTFORM has a driver program. i.e. Smart form/Script has to be called into a program. And this Driver program is in turn assigned to the relevant output type, And the output type is assiged to appropriate level of a transaction i.e. at the header level of an order or invoice etc.
T-code: SE71 is used to design SAP script.
T-Code: SMARTFORMS is used for designing Smart Forms.
To find out whether a script or Smartform is used in any particular case..........you have to look into the <b>Driver program</b> that is assiged to the output type.
Hope this helps..............
<b>REWARD POINTS IF HELPFUL.</b>
Regards
Sai
Maybe you are looking for
-
InDesign Placed Text Linking Issue
Hi - I've just recently updated to CS6 and am having an issue with linking placed text files. When I place the Word Doc into the InDesign file initially (not in position), the link to the original document is present in the 'Links' window as expected
-
Hi, I've just bought a re-furbed mac book pro (2GHz, 512Mb) and I can't start OS X 10.4.9, i get the same error message 'panic(cpu 0 caller 0x0039BC83): unable to find driver for this platform: "ACPI"' and then a series of code. Worked OK when I firs
-
New ti mac////have old sony cam corder modle ccd-tr940 no fire wire connect
can i use the camcorder or is there an adapter i can use. how can i convert analog to digital? mini mac Mac OS X (10.3.8)
-
Update Vendor Search Term #2 after saving.
Hello Xprts, I've been trying by several ways to update the search term #2 of the vendor master data transaction (xk01) after saving the record. The tcode has 2 badi's : VENDOR_ADD_DATA and VENDOR_ADD_DATA_CD but none of them has the right Method to
-
Check PR quantity againt outline agreement
user gets an error message when he creates a new PR comparing with open target quantity of that agreement.