How to create a variant to a report from another program at run time
Hi experts,
when i am using FM : /OSP/REPORT_CREATE_VARIANT to create a report variant from a program then i am getting an error 'For object /OSP/ERPNR , number range interval 01 does not exist ', how should i avoid it or can any one help me out to create a report variant from another program at run time with the results of the program.so that i can execute the report from here with this variant
If i understand you,
- You can use a FM like [RS_CREATE_VARIANT|https://www.sdn.sap.com/irj/sdn/advancedsearch?cat=sdn_all&query=rs_create_variant+&adv=false&sortby=cm_rnd_rankvalue] to create a variant and then use it in the [SUBMIT|http://help.sap.com/erp2005_ehp_03/helpdata/EN/fa/096d67543b11d1898e0000e8322d00/frameset.htm] statement USING SELECTION-SET.
- But you may also use SUBMIT with WITH parameters which doesnt require variant creation and with much less programming efforts.
- You can mix the two solutions also.
So what is you actual requirement, also look at some documentation like [ Scheduling a Job: Full-Control Method|http://help.sap.com/erp2005_ehp_03/helpdata/EN/fa/096ce5543b11d1898e0000e8322d00/frameset.htm]
Regards
Similar Messages
-
How to start Flash Media Encoder 3.2 from Flex application with run time parameters?
Hello ,
I'm developing the application to stream High Quality video.While streming by default camera/microphone settings the qulaity of streaming is not upto my expected level.I want to stream through Flash Media Encoder.My aim is the user login to the application.Video/audio qulaity details are retrived from shared object stored in the client machine.The login user name only gathered at run time & it will be the streaming profile name to Encoder.Once the the Encoder started the outgoing video will be come into screen to client.Please guide me How to start Flash Media Encoder 3.2 from Flex application with run time parameters(User name as streaming name) without manually start the FME?
Thanks in advance.
Regards
SasharyuvaHi MarcSaphiron,
Could you please send the samples?It will be much helpful to complete my
job within the deadline.
Thanks in advance.
Regards,
Sasharyuva -
How to call an alv report from another program and return back
Hello ,
I am calling one abap program (Prgm B) from another program (Prgrm A).
Here, Prgm B is an ALV report. I have fetch some data from Prgem B that gets stored in an internal table.
Now, I am using below code in Prgrm A,
SUBMIT Prgrm B VIA SELECTION-SCREEN
WITH SELECTION-TABLE rspar
EXPORTING LIST TO MEMORY
AND RETURN.
When Prgrm A executed, it lead me to selection screen of Prgrm B and when I click F8, it shows me the report output, In short, it doesnt return back to Prgrm A. It ends up showing me the alv report if Prgrm B even afetr using RETURN statement.
I want to get back to Prgrm A by fetching some data from Prgrm B.
Please let me know, if i am missing something.
Regards,
SeemaHi Seema,
Refer below code.
DATA: v_matnr LIKE mara-matnr.
DATA: t_listobject TYPE abaplist OCCURS 0 WITH HEADER LINE.
DATA: t_mara TYPE mara OCCURS 0 WITH HEADER LINE.
DATA: BEGIN OF t_ascilist OCCURS 0,
line(200).
DATA: END OF t_ascilist.
data var(3) type c.
SELECT-OPTIONS: s_matnr FOR v_matnr.
var = ' 3'.
START-OF-SELECTION.
SUBMIT ztestaks1 WITH s_matnr IN s_matnr EXPORTING LIST TO MEMORY
AND RETURN.
CALL FUNCTION 'LIST_FROM_MEMORY'
TABLES
listobject = t_listobject
EXCEPTIONS
not_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ELSE.
CALL FUNCTION 'LIST_TO_ASCI'
* EXPORTING
* LIST_INDEX = -1
* WITH_LINE_BREAK = ' '
TABLES
listasci = t_ascilist
listobject = t_listobject
EXCEPTIONS
empty_list = 1
list_index_invalid = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ELSE.
WRITE:/ 'Below are the lines from the submitted program.'.
LOOP AT t_ascilist.
WRITE:/ t_ascilist-line.
ENDLOOP.
SKIP 2.
ENDIF.
ENDIF.
IMPORT t_mara FROM MEMORY ID 'T_MARA'.
WRITE:/
'Here is the output from the table exported from the submitted program.'
LOOP AT t_mara.
WRITE:/ t_mara-matnr.
ENDLOOP.
Submitted program
REPORT ZTESTAKS1.
DATA: v_matnr LIKE mara-matnr,
v_maktx LIKE makt-maktx.
DATA: t_mara TYPE mara OCCURS 0 WITH HEADER LINE.
DATA: BEGIN OF t_makt OCCURS 0,
matnr LIKE makt-matnr.
DATA: END OF t_makt.
SELECT-OPTIONS: s_matnr FOR v_matnr,
s_maktx FOR v_maktx.
START-OF-SELECTION.
SELECT matnr INTO TABLE t_makt
FROM makt
WHERE matnr IN s_matnr
AND maktx IN s_maktx.
if not t_makt[] is initial.
SELECT * FROM mara
INTO TABLE t_mara FOR ALL ENTRIES IN t_makt
WHERE matnr = t_makt-matnr.
endif.
EXPORT t_mara TO MEMORY ID 'T_MARA'.
WRITE:/ 'This list is from the submitted program'.
SKIP 1.
LOOP AT t_mara.
WRITE:/ t_mara-mtart.
ENDLOOP.
Hopes this helps you.
Thanks,
Ashok. -
How can I print directly print a report from another app?
Hi, Can I print a report (printer schedule immediate) passing parameters from another application? Like a html page!
Thanks a lot. R.I can't use the url (for example):
http://HOST:9704/xmlpserver/servlet/scheduler?ujobname=test_print.xdo&d_printerd_p_gname0=direct&show_conf_page=true&d_method0=d_printer0&job_locale=it_IT&save_output=off&mode=schedule&save_data=off&ujobdesc=test_print.xdo&stype=simple_immediate&_xschurl=_xpt%3D%26WebDoc_Id_Page_Id%3D34132_233%26_xdo%3D%2Ftest_print%2Ftest_print.xdo%26_xpf%3D%26Store_Timezone%3DEurope%2FRome%26_xf%3Dpdf&report_url=%2Ftest_print%2Ftest_print.xdo&submitted=true&d_printerd_p_name0=bridgept1&d_printerd_copy0=1
? -
How to change the title of a report by programmation at the run time?
Hi,
I would like to change the title of my report at the run time.
Is it possible?
If someone can help me...
Thanks,
Mbohello,
what do you mean with "title" ?
a couple of approaches :
- Runtime Customization
- lexicals
- before report escape HTML
regards,
the oracle reports team --pw -
Calling a report from another program
Hi friends,
I want to run an existing report from one function module and I need the output in an internal table for further processing.But I don't want to change the called program for any export to memory.How can we do it ?
Thanks in advance,
JobyHi,
U can do by using
SUBMIT PROGRAM VIA SELECTION-SCREEN .
Bye -
How to create check box in ALV Reports?
how to create check box in ALV Reports?
Hi
check the report BCALV_TEST_GRID_EDITABLE
or
check this report
REPORT ZRFC346_TST.
TABLES:SFLIGHT,RL034.
TYPE-POOLS:SLIS.
INCLUDE:<ICON>,<SYMBOL>.
DATA: G_REPID LIKE SY-REPID,
G_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV,
G_IT_SORT TYPE SLIS_T_SORTINFO_ALV,
G_LAYOUT TYPE SLIS_LAYOUT_ALV,
G_TABNAME_HEADER TYPE SLIS_TABNAME,
G_TABNAME_ITEM TYPE SLIS_TABNAME,
G_KEYINFO TYPE SLIS_KEYINFO_ALV,
G_VARIANT LIKE DISVARIANT,
G_EXTAB TYPE SLIS_T_EXTAB,
I_SLIS_EXIT_BY_USER TYPE SLIS_EXIT_BY_USER.
DATA: XEVENT TYPE SLIS_T_EVENT,
AEVENT TYPE SLIS_ALV_EVENT,
VARIANT LIKE DISVARIANT,
LAYOUT TYPE SLIS_LAYOUT_ALV,
ASP_GROUP TYPE SLIS_SP_GROUP_ALV,
GT_SP_GROUP TYPE SLIS_T_SP_GROUP_ALV,
EXTAB TYPE SLIS_T_EXTAB WITH HEADER LINE,
XFIELD TYPE SLIS_T_FIELDCAT_ALV,
AFIELD TYPE SLIS_FIELDCAT_ALV,
G_SUCOMM LIKE SY-UCOMM,
G_SELFLD TYPE SLIS_SELFIELD.
DATA: SAV_SY_REPID LIKE SY-REPID.
CONSTANTS: CON_SFLIGHT TYPE LVC_FNAME VALUE 'SFLIGHT',
CON_DISPLAY_FULL TYPE I VALUE 3.
Data to be displayed
DATA: BEGIN OF GT_SFLIGHT OCCURS 0.
INCLUDE STRUCTURE SFLIGHT.
DATA:ACTIVATE(1).
DATA: END OF GT_SFLIGHT.
INITIALIZATION.
*........Initialisierung...............................................
PERFORM INITIALIZATION_RL034.
*........Field cata....................................................
PERFORM FIELD_CAT.
*........SPECIAL GROUP.................................................
PERFORM E07_SP_GROUP_BUILD USING GT_SP_GROUP[].
START-OF-SELECTION.
Selection
SELECT * FROM SFLIGHT INTO TABLE GT_SFLIGHT.
*........ALV CALL.......................................................
PERFORM ALV_CALL.
PERFORM USER_COMMAND_LOCAL USING G_SUCOMM G_SELFLD.
FORM USER_COMMAND_LOCAL *
--> G_UCOMM *
--> G_SELFIELD *
FORM USER_COMMAND_LOCAL USING G_UCOMM LIKE SY-UCOMM
G_SELFIELD TYPE SLIS_SELFIELD.
CASE G_UCOMM.
WHEN 'ACT'.
ENDCASE.
ENDFORM.
FORM ALV_CALL *
FORM ALV_CALL.
Call ABAP List Viewer (ALV)
G_LAYOUT-BOX_FIELDNAME = 'ACTIVATE'.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_BACKGROUND_ID = 'ALV_BACKGROUND'
I_BYPASSING_BUFFER = SPACE
I_BUFFER_ACTIVE = SPACE
I_CALLBACK_PROGRAM = SAV_SY_REPID
I_CALLBACK_PF_STATUS_SET = 'STATUS'
I_CALLBACK_USER_COMMAND = 'USER_COMMAND_LOCAL'
I_CALLBACK_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_END_OF_LIST = ' '
I_STRUCTURE_NAME = 'SFLIGHT'
I_BACKGROUND_ID = ' '
I_GRID_TITLE =
I_GRID_SETTINGS =
IS_LAYOUT = G_LAYOUT
IT_FIELDCAT = XFIELD[]
IT_EXCLUDING =
IT_SPECIAL_GROUPS = GT_SP_GROUP[]
IT_SORT =
IT_FILTER =
IS_SEL_HIDE = 'X'
I_DEFAULT = 'X'
I_SAVE = 'A'
IS_VARIANT =
IT_EVENTS = XEVENT
IT_EVENT_EXIT =
IS_PRINT =
IS_REPREP_ID =
I_SCREEN_START_COLUMN = 0
I_SCREEN_START_LINE = 0
I_SCREEN_END_COLUMN = 0
I_SCREEN_END_LINE = 0
IT_ALV_GRAPHICS =
IT_ADD_FIELDCAT =
IT_HYPERLINK =
I_HTML_HEIGHT_TOP =
I_HTML_HEIGHT_END =
IT_EXCEPT_QINFO =
IMPORTING
E_EXIT_CAUSED_BY_CALLER =
ES_EXIT_CAUSED_BY_USER =
TABLES
T_OUTTAB = GT_SFLIGHT
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM.
FORM status *
--> EXTAB *
FORM STATUS USING EXTAB TYPE SLIS_T_EXTAB.
SET PF-STATUS 'STAT' EXCLUDING EXTAB.
ENDFORM. " STATUS
*& Form INITIALIZATION_RL034
text
--> p1 text
<-- p2 text
FORM INITIALIZATION_RL034.
SAV_SY_REPID = SY-REPID.
ENDFORM. " INITIALIZATION_RL034
*& Form DEFINE_EVENTS_RL034
text
--> p1 text
<-- p2 text
FORM DEFINE_EVENTS_RL034.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
I_LIST_TYPE = 0
IMPORTING
ET_EVENTS = XEVENT.
exceptions
list_type_wrong = 1
others = 2.
ENDFORM. " DEFINE_EVENTS_RL034
*& Form FIELD_CAT
text
--> p1 text
<-- p2 text
FORM FIELD_CAT.
DATA: LS_FCAT TYPE SLIS_FIELDCAT_ALV,
L_LIN TYPE I.
REFRESH XFIELD.
1. per Default eingeblendete Felder *
*........Ikone/Symbol..................................................
CLEAR AFIELD.
DATA: LS1_FCAT TYPE SLIS_FIELDCAT_ALV,
L_LIN1 TYPE I.
CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
EXPORTING
I_STRUCTURE_NAME = CON_SFLIGHT
I_BYPASSING_BUFFER = SPACE
I_BUFFER_ACTIVE = SPACE
CHANGING
CT_FIELDCAT = XFIELD
EXCEPTIONS
INCONSISTENT_INTERFACE = 1
PROGRAM_ERROR = 2
OTHERS = 3.
DESCRIBE TABLE XFIELD LINES L_LIN1.
ADD 1 TO L_LIN1.
CLEAR LS_FCAT.
LS1_FCAT-FIELDNAME = 'ACTIVATE'.
LS1_FCAT-CHECKBOX = 'X'.
LS1_FCAT-KEY = 'X'.
LS1_FCAT-INPUT = 'X'.
LS1_FCAT-EDIT = 'X'.
LS1_FCAT-INTTYPE = 'C'.
LS1_FCAT-DATATYPE = 'CHAR'.
LS1_FCAT-INTLEN = 1.
LS1_FCAT-COL_POS = L_LIN1.
LS1_FCAT-SELTEXT_S = LS1_FCAT-FIELDNAME.
LS1_FCAT-SELTEXT_M = LS1_FCAT-FIELDNAME.
LS1_FCAT-SELTEXT_L = LS1_FCAT-FIELDNAME.
LS1_FCAT-SP_GROUP = 'A'.
APPEND LS1_FCAT TO XFIELD.
ADD 1 TO L_LIN.
ENDFORM. " FIELD_CAT
FORM E07_SP_GROUP_BUILD USING E07_LT_SP_GROUP TYPE SLIS_T_SP_GROUP_ALV.
DATA: LS_SP_GROUP TYPE SLIS_SP_GROUP_ALV.
CLEAR LS_SP_GROUP.
LS_SP_GROUP-SP_GROUP = 'A'.
LS_SP_GROUP-TEXT = 'SPECIAL'.
APPEND LS_SP_GROUP TO E07_LT_SP_GROUP.
ENDFORM.
Regards
Shiva -
MMPV - Close period - How to create a variant
Hello all,
Transaction MMPV is used to close the MM period and open a new one. Currently, we run this transaction every month MANUALLY.
We would like to create a variant that will open the new period automatically every month. The only problem is the period / year that changes every month (I do not know how to create a variant with changed values - if it is at all possible).
How can we create a variant that will run every month to close the MM period ?
Thanks for your help,
IsaacHello Isaac
It is possible......But to make it happen you need to go with date field and not with Period and year.
Steps -
1 - Enter field FROM Comp Code and TO Comp Code
2 - Enter the date (E.g - 05-Mar-2007)
3 - Save as varient....Give the varient names as required.
4 - Activate the 4th checkbox (Selection variable) in front of date field
5 - Click on button 'Selection variable' at the top of screen.
6 - Click on YELLOW light. This will turn it GREEN. Now you have 1st light as YELLO which was previously yello.
7 - Click on the down arrow just below the yello light.
8 - Select the appropriate option and save the varient.
The day of batch job scheduling depends upon the options you selected in the 8th step.
I hope it clarifies your dought and will allow you to create the varient as per your requirement.
Best Regards
Avinash -
Hi :
I developed a BDC program using call transaction, and also a tcode for this program.How can i add variants to this tcode.
from se38 when i enter program name and from menu bar im selecting variants tab, here im creating a new variant and saving it.
But when i execute my tcode, in selection screen i am not seeing variant option.
Do i need to add any code for creating a variant in my program?
Thanks.
RaghuHello,
CALl the Transaction U have created fro the BDC. It will show the selection screen. There u fill the data for the field and SAVE button will be there in the menu click it will ask for Variant name give it and save.
If useful reward.
Vasanth -
How to create a variant in ecatt?
Hi all,
I am new to Ecatt scripting. I hav a requirement from the user, that one ecatt is used for two sales org using two variants.
I recorded as per the requirement ( first i created one basic script and called it in a master script ). Now I need to create two variants for the master script for the sales org.
So could any one suggest how to create a variant in ecatt?
Thanks in advance.
Vijayakumar.GHello Vijay,
After recording parameterize everything whatever you want.
In parameterization table leave the value field as empty, I mean don't give any value.
Select the following in the menu,
Utilities>Test configuration>Create
Now, test configuration name will have the same of the test script name.
Provide the details in the configuration tab. Then in the variants tab select the second radio button "Internal variants".
In the variant table you can see the default variant "ECATTDEFAULT". You can make use of this also. Otherwise you can also create your own variants by clicking "Insert variant" button.
The variables whatever you have created in the test script will be there in the table. Now, Create variant and provide values for each variables.
You can also select the variants which need to be executed.
Now you can run the test configuration. It will be running number of times according to the created number of the variants.
You can also create Test data for your test script and configuration.
Try this, I hope it will help.
Feel free to reward if it helps.
Regards,
Gopi
Edited by: Gopinath K S on Oct 7, 2008 7:37 AM -
How to create a variant in VA01
Hi Gurus,
Can you teach me how to create a variant in VA01? I'd like to have a default value in the sold to party field.
Thanks,
Paulhi,
To show a default sold-to-party in this field when the user creates a sales order (VA01) we can use a function exit .This function exit is located in enhancement no V45A0002 . Before we can choose the exit we have to create a project in CMOD after that enter V45A0002 in the enhancement field and click on the components . In the components you will see the exit EXIT_SAPMV45A_002 . This exit is used for our purpose.
Double clicking on this exit will takes us to function builder (SE37) . This function exit has one exporting parameters and two importing parameters, we are interested in exporting parameter which is E_KUNNR of type KNA1-KUNNR i.e if we move the desired customer name to this structure(E_KUNNR) it will be shown in the field as the default value when we create the sales order. This function also contains a customer include ZXVVA04 . This include will be used to write our custom code .
Double clicking on this include and it will prompt us that this include does not exists do you want to create this object ,select yes and the include will be created .In this include we can write our own code that will fill the field E_KUNNR.
e.g. E_KUNNR = 301.
Activate the include and Activate the project. Now when ever the SALES ORDER will be created , sold-to-party field will come up with a predefined customer .
regards
sadhu kishore -
How to create a variant selection screen
Hi experts,
Can you tell me " How to create a variant selection screen ".
Please it's urgent.........
Thanks
BasuHi ,
Goto your selection screen
Make entries in the fileds od the selection screen
press save button, it will ask you for the mane of the Variant
Give the name of the Variant and save it
Variant is now created for the selection screen.
Reward if useful.
Regards,
Shilpi -
How to create t-code for a table and how to create transaction variant???
Hi,
I have created a custom table zsark.
Now my requirement is : I have to create a transaction variant zsark_var for sm30 and table zsark. I have to disable the output of the first screen. I have to assign the transaction variant to the transaction code of table zsark.
Now,
1. how to create transaction code to a table. Can any one give me the
staps??
2. how to create transaction variant for the above requirement???
Thanks & Regards,
SarkarHi
1 Goto SE93 transaction
2 Choose 5th option Transaction with parameters
3 Give transaction : SM30, Check Skip Initial Screen Press Enter
4 Goto Bottom left corner, click F4 select viewname, on right hand side give table name
5 Press one more time F4, choose update , mark it X on right side.
6 save the transaction.
Thanks
sandeep
reward if helpful -
How to create pdf files in UNIX directory from oracle reports
I would like to know how to create pdf files in UNIX directory from oracle reports.
Thanks,Please make your question more clear . Also mention the reports version.
1) If you are runnning reports in Unix, you can give
.... destype=file desformat=pdf desname=<filename>
in command line
Please refer docs below.
2) If by your question you mean
"My reports server is running in Windows but I want to ftp my files to Unix after creating it"
then the answer is that you can use pluggable destination "ftp"
.... destype=ftp desformat=pdf desname=<ftp url>
Pluggable destinations download
http://otn.oracle.com/products/reports/pluginxchange/index.html
Thanks
Ratheesh
[ All Docs ]
http://otn.oracle.com/documentation/reports.html
[ Publishing reports to web - 10G ]
http://download.oracle.com/docs/html/B10314_01/toc.htm (html)
http://download.oracle.com/docs/pdf/B10314_01.pdf (pdf)
[ Building reports - 10G ]
http://download.oracle.com/docs/pdf/B10602_01.pdf (pdf)
http://download.oracle.com/docs/html/B10602_01/toc.htm (html)
[ Forms Reports Integration whitepaper 9i ]
http://otn.oracle.com/products/forms/pdf/frm9isrw9i.pdf -
How to create rtf template to view report in Word and Excel, with numeric f
Hi,
Please help me!
How to create rtf template to view report in Word and Excel, with numeric formatted fields (like this 999 999 999,99 with spaces between numbers) and then end user be able to process those fields with Excel tools (sum, etc).
Thank you.From what I have seen Excel can not handle 999 999 999.00. You can use 999999999.00 and then format it as you want in the xls bt you can not have values like 999 999 999.00 coming from publisher output and have functions on the values in Excel
Tim
Maybe you are looking for
-
New to the forums and have looked but can not find an answer to my question. I have the HP s5503w SlimLine desk computer; what I need an answer to is where on the motherboard do I plug in the card reader that I have. Have searched both here and on th
-
WDS PXE Uefi not working in AD integrated mode, TFTP to slow
Dear all 1 Physical host: W2k12R2, 1 Hyper-V virtual switch. 1 Hyper-V VM with W2k12R2 DC with DNS, DHCP, WDS. 1 Empty Hyper-V VM Generation 2 UEFI booting from network. Problem: Error "PXE-E16: No offer received" on the empty Hyper-V VM when trying
-
This pad is so stupid, iCloud iOS5, iTunes pallet IID etc etc, I have ios5, I have an iCloudd account it will not send or receive mails in iCloud, please Do not be tech here, I do not even understand stmp etc, why is it not getting mail in easy steps
-
Hi Gurus, Please tell me the ALE and Idocs configuration settings Thnaks in advance
-
Failed to execute sql statements
Hi all, We have a cluster domain on a AIX 4.3 machine with jdk IBM 1.3. Sometimes we get the following error at jdbc log files at one node. When we restart this node( it is always the same) the problem stopped. Has anyone dealt with this problem Vers