Form rotuine for script
Hi Gurus,
How to attch or code form routine into driver program for Script?
Plz reply fast its very urgent
Martin
Hi Martin,
Lets suppose if u want to fetch the payment due for an invoice.
Code this form routine in your script.
/: PERFORM GET_PYMT_DUE_IN IN PROGRAM ZSROINVOICE
/: USING &VBDKR-VBELN&
/: USING &VBDKR-FKDAT&
/: USING &VBDKR-ZTERM&
/: CHANGING &PYMNTDUE&
code it in ur driver program to fetch the details.
FORM get_pymt_due TABLES i_intpar STRUCTURE itcsy
i_outpar STRUCTURE itcsy.
DATA : wa_fkdat LIKE sy-datum,
wa_ztag2 LIKE t052-ztag2,
wa_pymnt LIKE sy-datum.
READ TABLE i_intpar WITH KEY name = 'VBDKR-FKDAT'.
IF sy-subrc = 0.
CONCATENATE i_intpar-value6(4) i_intpar-value3(2)
i_intpar-value+0(2)
INTO wa_fkdat.
ENDIF.
READ TABLE i_intpar WITH KEY name = 'VBDKR-ZTERM'.
IF sy-subrc = 0.
Payment Terms
SELECT SINGLE ztag2
INTO wa_ztag2
FROM t052
WHERE zterm = i_intpar-value.
ENDIF.
wa_pymnt = wa_fkdat + wa_ztag2.
MOVE 'PYMNTDUE' TO i_outpar-name.
CONCATENATE wa_pymnt6(2) '.' wa_pymnt4(2) '.' wa_pymnt+0(4) INTO
i_outpar-value.
APPEND i_outpar.
CLEAR i_outpar.
ENDFORM.
Hope this will help you.
Revert back for furthe rassistance
Similar Messages
-
What is the form name (SAP script name ) for KO02 output .
Hai ,
what is the form name (SAP script name ) for KO02 output . and also pl guide how to customize that.
thank u in advancespro---->controlling ->internal Order->Order Master Data----> Prepare Output and see the documentation of this.
Regards
Peram -
How to print " Duplicate " in FORM ( either Sap Script or Smart Forms )
hi,
How to print " Duplicate " in FORM ( either Sap Script or Smart Forms ) if trying to take second Print Out and the FORM is already Printed.
Please let me know the condition that we should go for.If possible let me know the SAMPLE code since this will be used in most of the FORMS.
Regards
AviHi
It depends on which print you're working.
If it's a print of standard document you can check the NAST (VSTAT field) table in order to know if the document was printed.
If a message is created you can find the hit in NAST table:
VSTAT = 0, document not printed;
VSTAT = 1, documment printed
VSTAT = 2, print is failed
If you mean a custom print I believe you need to create a log like NAST table.
Max -
Hi Experts,
We have implemented SAP notes, and technically we do not have any issue in printing form 16a for vendors in new format. Only issue is, this new form 16 prints 3 pages & my tax guys wants it in one page where ever possible.
My question is, which one is advisable : direclty do the changes in standard sap form, or copy this and do the changes.
And
If I should copy from POriginal and do the changes, then wherever I have to change the form name?
Please advise.
ShaileshHi Shailesh
always copy the SAP form and make the changes.. thats the best practice...
I think you need to assign the new form in J1INCRT.. (Financial Accounting Financial Accounting Global Settings Withholding Tax Extended Withholding Tax Postings India Witholding Tax Certificate for vendors and Customers Maintain Number RangesMaintain Number Groups and Sap Script Forms)
Br, Ajay M -
PDF Form Javascript for getting User LoginName
Please let me know PDF Form JavaScript for showing User Login Name (login id) in the Text Field (text1), when using Button (button1).
As noted there has to be a special folder level script installed on each user's system. This script can be written to access individual properties of the identity object or only a specific property. One can also create a function to access the identity object or even create new properties.
-
Required sample coding for invoice billing for script
Hi,
Required sample coding for invoice billing for script in form and endform.
please help me its very urgent issue. thanks in advance.
thanks®ards
sirishHi Sirish,
these are some of the links where u can find ur solution plz check...
<u>
SAP SCRIPT
SAP SCRIPT
https://www.sdn.sap.com/irj/sdn/advancedsearch?cat=sdn_all&query=invoicebillingfor+script&adv=false&sortby=cm_rnd_rankvalue</u>
regards,
Sana M. -
HCM Processes and Forms : Using single Form Scenario for Multiple Countries
Hi ,
I have a requirement to design a HCM P&F form ( Single Process, Single Form Scenario ) to support multiple countries. Form fields should be visible/invisible based on the country ( derived from the login Manager). please help me with the following questions.
1. Is it right way to enable/disable the fields in the same form scenario for multiple countries ( Approx. 20-25 countries)
2. Is there any limitation to no. of fields on the form? does the form performs well with multiple dynamic conditions?
3. If yes, what is the best way to do this? through Java Script / Back end Generic Service?
Thanks in Advance,
VR.Hi VR,
1. Is it right way to enable/disable the fields in the same form scenario for multiple countries ( Approx. 20-25 countries)
-You can use same form scenario or process for multiple countries if you are using fields based on international structure HCMT_BSP_PA_XX_R*. If you intend to use country specific fields then you may like to use different form scenario for different countries.
2. Is there any limitation to no. of fields on the form? does the form performs well with multiple dynamic conditions?
- As such there is no limiation for the fields.Yes, form performs well with multiple rule configurations.
3. If yes, what is the best way to do this? through Java Script / Back end Generic Service?
I interpret you would like to derive & show fields based on same backend logic, in that case you should generic service.
If you want to show fields based on manager's logon then you should also use authorization BAdi.
Regards
Pooja -
Form routines in scripts...
hi everybody,
can any one tell me the procedure how to use form routiens in scripts.
thnx in advance,
santosh.Hi
See the sample routines
How to call a subroutine form SAPscripts
The Form :
/:PERFORM CDE_CENT IN PROGRAM ZKRPMM_PERFORM_Z1MEDRUCK
/:USING &EKKO-EBELN&
/:CHANGING &CDECENT&
/:ENDPERFORM
The report :
REPORT zkrpmm_perform_z1medruck .
DATA : BEGIN OF it_input_table OCCURS 10.
INCLUDE STRUCTURE itcsy.
DATA : END OF it_input_table.
déclaration de la table output_table contenant les
variables exportées
DATA : BEGIN OF it_output_table OCCURS 0.
INCLUDE STRUCTURE itcsy.
DATA : END OF it_output_table.
DATA : w_ebeln LIKE ekko-ebeln,
w_vbeln LIKE vbak-vbeln,
w_zcdffa LIKE vbak-zcdffa.
FORM CDE_CENT
FORM cde_cent TABLES input output.
it_input_table[] = input[].
it_output_table[] = output[].
READ TABLE it_input_table INDEX 1.
MOVE it_input_table-value TO w_ebeln.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = w_ebeln
IMPORTING
output = w_ebeln.
SELECT SINGLE zcdffa FROM ekko
INTO w_zcdffa
WHERE ebeln = w_ebeln.
it_output_table-name = 'CDECENT'.
MOVE w_zcdffa TO it_output_table-value.
MODIFY it_output_table INDEX 1.
output[] = it_output_table[].
ENDFORM.
REPORT ZMPO1 .
form get_freight tables in_par structure itcsy out_par structure itcsy.
tables: ekko,konv,t685t.
data: begin of itab occurs 0,
ebeln like ekko-ebeln,
knumv like ekko-knumv,
end of itab.
data: begin of itab1 occurs 0,
knumv like konv-knumv,
kposn like konv-kposn,
kschl like konv-kschl,
kbetr like konv-kbetr,
waers like konv-waers,
kwert like konv-kwert,
end of itab1.
data: begin of iout occurs 0,
kschl like konv-kschl,
vtext like t685t-vtext,
kbetr like konv-kbetr,
kwert like konv-kwert,
end of iout.
data v_po like ekko-ebeln.
read table in_par with key 'EKKO-EBELN'.
if sy-subrc = 0.
v_po = in_par-value.
select
ebeln
knumv
from ekko
into table itab
where ebeln = v_po.
if sy-subrc = 0.
loop at itab.
select
knumv
kposn
kschl
kbetr
waers
kwert
into table itab1
from konv
where knumv = itab-knumv and
kappl = 'M'.
endloop.
loop at itab1.
if itab1-kposn <> 0.
select single * from t685t
where kschl = itab1-kschl
and kappl = 'M'
and spras = 'EN'.
iout-vtext = t685t-vtext.
iout-kschl = itab1-kschl.
iout-kbetr = itab1-kbetr.
iout-kwert = itab1-kwert.
append iout.
clear iout.
endif.
endloop.
sort itab1 by kposn.
loop at iout.
sort iout by kschl.
if ( iout-kschl eq 'GSDC' OR
iout-kschl eq 'GSFR' OR
iout-kschl eq 'GSIR' ).
at end of kschl.
read table iout index sy-tabix.
sum.
write:/ iout-kschl,iout-vtext,iout-kwert.
out_par-name = 'A1'.
out_par-value = iout-vtext.
append out_par.
out_par-name = 'A2'.
out_par-value = iout-kwert.
append out_par.
endat.
endif.
endloop.
endif.
endif.
endform.
IN THE FORM I AM WRITING THIS CODE.
/:DEFINE &A1& = ' '
/:DEFINE &A2& = ' '
/:PERFORM GET_FREIGHT IN PROGRAM ZMFORM_PO1
/:USING &EKKO-EBELN&
/:CHANGING &A1&
/:CHANGING &A2&
/:ENDPERFORM
&A1&
&A2&
This Code is to be written in the PO form under ADDRESS window.
/:DEFINE &A1& = ' '
/:DEFINE &A2& = ' '
/:DEFINE &A3& = ' '
/:DEFINE &A4& = ' '
/:DEFINE &A5& = ' '
/:DEFINE &A6& = ' '
/:PERFORM GET_VENDOR IN PROGRAM ZMFORM_PO
/:USING &EKKO-EBELN&
/:CHANGING &A1&
/:CHANGING &A2&
/:CHANGING &A3&
/:CHANGING &A4&
/:CHANGING &A5&
/:CHANGING &A6&
/:ENDPERFORM
&A1&
&A2&
&A3&
&A4&
&A5&
&A6&
Reward points for useful Answers
Regards
Anji -
Import PE51 Form to SAP Script
Hello Experts,
I am Importing PE51 form to SAP Script.The Problem is after Executing the Program RFFOUS_C the PE51 form is coming...into SAP Script But it(PE51 Form) is Compressing?.I don't know why?.But when i executing the Program RPCDTCU0_CE.The PE51 Form is Showing Exactly..without any Compression.
In Searching the Forum i have found these threads..But in these threads i haven't found any Solution
Integration of SAP Script form and HR Form
PE51 - Form Editor
Thanks in advance.Hey ankur,
Normally you get dashes instead of line because of two reasons:
1. Because the Font Size you are using for the Line is Small hence it cannot print a continous Line..
Please increase the Font Size and try checking in the Layout.
2. Sometimes the SAP printer you have configured does not support the Font Type You have used in Scripts...
Kindly check T-CODE SPAD to see the Device type of the printer you are using supports that font.
Hope this helps you...Have a nice day at work..
Thanx,
Navin.... -
Include program for script dump error in data type
Hi i have written following subroutine for script.
FORM WITHHOLD TABLES in_tab STRUCTURE itcsy
out_tab STRUCTURE itcsy.
data: a_SKFBT TYPE REGUP-SKFBT,
A_DMBTR TYPE REGUP-DMBTR,
W_TAX1(18) TYPE REGUP-SKFBT.
read table in_tab WITH KEY NAME = 'REGUP-SKFBT'.
read table in_tab INDEX 1.
check sy-subrc = 0.
a_SKFBT = in_tab-value.
read table in_tab WITH KEY NAME = 'REGUP-DMBTR'.
read table in_tab INDEX 2.
check sy-subrc = 0.
a_DMBTR = in_tab-value.
W_TAX = ( a_SKFBT - a_DMBTR ).
read table out_tab with key name = 'W_TAX1'.
IF SY-SUBRC = 0.
out_tab-value = W_TAX1.
modify out_tab INDEX 1.
ENDIF.
ENDIF.
endform.
above program is giving dump .
while deduction values in w_tax .
what type of variables i shold take here..Hi Venkat,
Your declaration for the tax variable is wrong. When you have specified a table field there is not any need to mention the number of characters for that variable.
Simply declare as W_TAX type REGUP-SKFBT and
W_TAX1(16) type c.
After computing W_TAX, Move W_TAX to W_TAX1.
Regards,
Anil -
is there a way of finding out if a given program is a driver program for scripts.
reply asap.
points will be rewarded.Hi..
You can find the link between the Form and the Print program in Table <b>TNAPR</b>.
<b>Fields</b>
FONAM -> FORMNAME
PGNAM -> PROGRAM NAME
The other way to find is Open the Text elements of any window
and Select the Menu path Sytax->check
<b>Reward if Helpful</b> -
Form routine for sales order adobe forms
Hi Friends,
I have a requirement to create z adobe forms for sales order for customized output type.
When i checked, there is no form routine designed for calling the adobe forms.
So, i am planning to copy the standard print program which is available for script and smartforms and creating a z form routine to include the function modules for calling the adobe form.
Can any one please let me know whether have you worked in any of the same kind of situations and my apporach is ok or anything else can be done.
Thanks & Regards,
PrabuHello,
Plz check your caller program for the same and just find out the output type. for that purpose use the Tcode: NACE for finding the output type than proceed accordingly.
Regards,
Akg -
Hello All,
Now that I have found the form, (thanks for helping on that) - further.
I have to find why a wrong logo is being printed on the form.
Where are the logo files stored?
There is a Logo Window which has this code :
IF &T001-BUKRS& = 'BDC'
INCLUDE ZHEX-MACRO-BEEB-300-BMON OBJECT TEXT ID ST
ELSE
INCLUDE ZHEX-MACRO-300BMON OBJECT TEXT ID ST
ENDIFHi
For Scripts Logos can be on desktop or anywhere on your SAP system, we convert them to .tiff files.
for smartforms check the Transaction SE78 for
Graphics .
To create a logo in SAP printouts just do the following
1. Save a Logo using Imaging, Paint shop Pro or Corel Draw as Tiff file.
2. Run program RSTXLDMC and enter the following parameters
Enter file name C:\COMPLOGO.TIF
UOM CM
Line width for text 132
Text name ZHEX-MACRO-COMPLOGO
Text ID ST
Text language = E
Number of Tiff gray levels (2,4,9) 2
3. Then Create a new window 'COMP' with attributes;
Window COMP description Company Logo
Left margin 7.00 CH window width 10.00 CH
Upper margin LN window height 8.00 LN
Finally in the text element, mention
/: INCLUDE 'ZHEX-MACRO-COMPLOGO' OBJECT TEXT ID ST LANGUAGE 'E'.
Please note that if object name is not indicated as 'ZHEX... the logo may not be printed!
You will not be able to see the logo in a test print. The same will be printed in actual printout.
Reward points for useful Answers
Regards
Anji
Message was edited by:
Anji Reddy Vangala -
How to publish infopath form using powershell script in infopath 2010?
Is any approach for such solution.Hi,
Try below command:
Uninstall the existing solution (based on the from file name):
Uninstall-SPInfoPathFormTemplate -Identity Exampleform.xsn
Install the new solution (based on the from file name):
Install-SPInfoPathFormTemplate -Path C:\Form.xsn
Disable feature on site collection level
Disable-SPInfoPathFormTemplate -Identity "Form.xsn" -Site http://SPSite
Enable feature on site collection level
Enable-SPInfoPathFormTemplate -Identity "Form.xsn" -Site "http://SPSite"
See this blogs for your ref:
http://rgielen.blogspot.in/2010/11/deploy-infopath-2010-forms-with.html
http://mysharepointwork.blogspot.in/2010/09/deploy-infopath-forms-with-powershell.html
Hope it could help
Hemendra: "Yesterday is just a memory,Tomorrow we may never see"
Whenever you see a reply and if you think is helpful, click "Vote As Helpful"! And whenever
you see a reply being an answer to the question of the thread, click "Mark As Answer -
Is there any Forms extension for Jdeveloper9. I am testing my Oracle Applications to launch forms using the embedded web server from Jdeveloper9. How can I test forms. Do I need Forms extension for Jdeveloper 9
You could try to deploy your jdeveloper web application (that opens forms applet) into forms OC4J in your developer suite home. This is not automated task from JDeveloper by default, but you can do it with custom ant scripts.
Maybe you are looking for
-
can anyone help me through this? i have had this happen a few times but my iTunes list usually comes back just fine and i have all of the content restored.
-
IBooks Author crashes every two minutes. What's going on?
iBooks author crashes literally every few minutes, and the error message reads "iBooks author failed while using the iBooks Author plug-in. Click here to re-open". I tried uninstalling and reinstalling the app itself. I'm running the latest release o
-
Invoice Verification and valuated blocked stock
Hi, We are using movement types 107 / 109 for modeling stock in transit. And we have trouble in invoice entry processing. We perform a good receipt with movement type 107 (Valuated Blocked Stock), but no 109 (storage receipt) is performed, when enter
-
Session State Protection - Arguments must have Checksum - Help Required
Hi everyone, I am using apex 4.0 and have set: Session State Protection = True Page Access Protection = Arguments must have checksum Application Item Protection = Cecksum required - Session Level Page Data Entry Item Protection = Cecksum required - S
-
I had Google as default search engine. Now, Yahoo shows up and even when I delete it, close firefox 8.0, restart it, Yahoo again rears its ugly head. Nothing seems to fix this. Any program I install that is tied in to Yahoo, I specifically exclude th