Variants in ModulePool program
Hi,
Is there any way to create user variants in module pool programming as we do in reports.
Thanks in advance,
Reg,
HariRaam.
RS_CREATE_VARIANT Creating a variant (not using a selection screen)
RS_VARIANT_CATALOG Returns variant directory for a report in an internal table
RS_VARIANT_EXISTS Checks whether variant exists
RS_VARIANT_TEXT Returns text for a variant
regards
vinod
Similar Messages
-
How can we pass the select-option value to modulepool program?
hi,
how can we pass the select-option value to modulepool program ?
Because if i declared select-options in executable program and i used SSCRFIELDS to define push buttons in selection screen.
My requirement if enter the values to select-options and press UPDATE pussbotton then i want call screen which contains tablecontrol.
How i get select-option values to PAI of call screen for getting the data from database table to my internal table?Oh I thought that you have selection-screen and again you are working on dialog programming.
if you want to use select-option directly in module pool then it is not possible.
but you can do other way.
create two varaiables
data : v_kun_low like kna1-kunnr,
v_kun_high like kna1-kunnr.
use these two variables in layout ,let user knows that he can not give options like gt,lt,eq ,it will be always BT.
and also when you see normal report program,you can use multiple values in either low or high,but here it is not possibel.
use can enter only low value and high value.
when you come to program point of view
declare one range
ranges r_kunnr for kna1-kunnr.
do the coding like
r_kunnr-low = v_kun_low.
r_kunnr-high = v_kun_high.
r_kunnr-options = 'BT'.
r_kunnr-sign = 'I'.
append r_kunnr.
now you can use r_kunnr in select query ,it will work like select-option.
other than this there is no option.
Thanks
Seshu -
Download and Upload Modulepool program
hai all,
Could any one say how to Download and Upload Modulepool program from sap.
Thanks,
Jeevan.Hi Puduru
Welcome to ABAP forums.
If you just want to export Module pool program once, you can use transaction SE80 and menu point Utilities->More Utilities->Upload/Download->Download option ( for each include / component ).
Save it as a text file and then repeat the same process.
Here's other programs for the same functionality. You can use one of them.
http://www.members.tripod.com/abap4/Upload_and_Download_ABAP_Source_Code.html
http://sap.ittoolbox.com/code/d.asp?d=1623&a=s
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/finding your code in bsp applications.article
http://www.geocities.com/rmtiwari/Resources/Utilities/WebViewer.html
http://www.dalestech.com/
Dont forget to rewards pts, if it helps ;>)
Regards,
Rakesh -
What is variant in ABAP Program Process Block in Process Chain?
I wrote an ABAP program:
REPORT ZTEST,
PARAMETERS: PROC(80) TYPE C.
I can test this PORGRAM from SE38, it shows me a pop-up screen for PROC and I can enter a value and execute.
Now I want to call this program ZTEST from a process chain. In Process Chain Selected a Process u201CABAP Programu201D. It asks me program name and Program variant, I entered Program Name as ZTEST and
Program variant as a character string HELLO.
When I execute Porcess Chain, ABAP Program errors saying that variant HELLO not found.
What is Program variant in ABAP Program Process in Process Chain?
Thanks,Dont get confused here.
Variant name is not which you are pasing to the program.
You enter some values inside the variant and you specify the program to take the input from the variant.
Suppose you have to pass 10 parameters to a program.
user1 creates a variant " hello1" which contains his own selection for the 10 values
user2 creates another variant "hello2" which contain his own set of selecion values.
When we use this program in PC, you can use the variant user1 or user2 as per our requirement.
please check if you are giving variant as input or the proc value.
Hope this helps,
Sri.... -
Creating a variant in my program?
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?You enter the selection-screen details in your program and hit the save button and next time you visit the program either thru custom tcode or thru se38 you will be able to see the variants u created
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. -
ALV Display Variant copying between programs
There is a report program say PROGRAM1 whose ALV display variants we want to copy to the ALV display variants of another program say PROGRAM2.
Both these program share the same ALV output structure design. My questions are
1) Can the display variants of an ALV be copied into another program.?
2) Can this be managed programatically?Hi,
Try using LVC_VARIANT_SELECT and LVC_VARIANT_SAVE fms.
First call LVC_VARIANT_SELECT to read variant from the first program and then call LVC_VARIANT_SAVE to save it for the second program.
Take a look at report BCALV_GRID_11 for reference
Sri
Message was edited by: Srikanth Pinnamaneni -
Whr to find modulepool program of aTransaction
Hi all,
I find main program for a transaction code as report in some entries of TSTC table but when i run a transaction i find the program as modulepool program from system status option. In which table can i find the respective modulepool program of a tcode.
for ez table entry for ME21N in TSTC is RM_MEPO_GUI and its corresponding program is SAPLMEGUI from system status option.
Message was edited by:
chandrahasaHi,
Run your Transaction.
Then the screen of your program Displays.
In the screen In the Right Bottom corner there will be your transaction name. Just click the Icon nearby and find your program name.
Thanks,
Reward If Helpful. -
Creating Variant in Dialog Program Screen
Hi All,
Can I create Variant in Dialog Program screen.If yes, how can I do this?
Thanks
Saurabhdfsdf
-
Copying ALV Display Variants between different programs
Is there a way to copy the ALV Display Variants from one program to another? I am NOT referring to selection screen variants.
An SAP standard program was copied to a Z program. Some changes were made to the logic. The original SAP program has many (100+) ALV Display Variants. I do not want to manually re-create them. Is there a way to copy these from one program to another (without using a custom program to manipulate the tables)?
Thanks.
NormHi norman,
even i was thinking the same while you passing the alv parameter is_variant, give the the program which is having 100 variants.
is_variant-REPORT = 'STANDARDPRG'.
this will import all varaints from it, but when you save any new one it will save in the same standard program.
regards
vijay -
How to handle two radio buttons in modulepool program
hi,
i am creating 2 radio buttons on the initial screen of a modulepool program, here i am unable ot handle those 2 radio buttons.
when executing by default these two radio buttons are selected.
pls send me the sample code that how to handle.Prasad,
In the Screen Painter, highlight both radio buttons at the same time (using CNTL key).
From menu bar, choose: Edit > Grouping > Radio Button Group > Define.
Now they are "linked" to each other.
Don;t forget those points. -
Find contents in variant for all programs
Hi All,
I have to find out a string in variant for all programs which are using that string .
I have to find out this devcq1 string in varints for all programs.
How can i do that one?Hi,
You can get the variant name from table VARID and then pass it to the FM RS_VARIANT_CONTENTS and search the return values for your specific content.
tables: varid.
select-options: s_report for varid-report.
data: begin of itab occurs 0,
report like varid-report,
variant like varid-variant.
data: end of itab.
data: i_val type standard table of rsparams with header line.
select report variant
from varid
into table itab
where report in s_report.
check sy-subrc = 0.
loop at itab.
CALL FUNCTION 'RS_VARIANT_CONTENTS'
EXPORTING
report = itab-report
variant = itab-variant
TABLES
valutab = i_val.
if sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
else.
loop at i_val.
.... <-- search i_val for devcq1 string
endloop.
endif.
endloop.
Regards.
Ferry Lianto -
Wht we do in modulepool programming
hi abapers,
can u plz guide me
1. wht we do in modulepool programming
2.can u plz send one senario to undersatnd the perpose.
thanks in addvanceHi,
Check these links.
http://wiki.ittoolbox.com/index.php/FAQ:What_is_module_pool_program_in_abap%3F
http://help.sap.com/saphelp_46c/helpdata/en/35/26b1aaafab52b9e10000009b38f974/content.htm
http://sap.mis.cmich.edu/sap-abap/abap09/sld011.htm
http://sap.mis.cmich.edu/sap-abap/abap09/index.htm
http://www.geocities.com/ZSAPcHAT
http://www.allsaplinks.com/files/using_table_in_screen.pdf
http://help.sap.com/saphelp_webas630/helpdata/en/9f/db9cdc35c111d1829f0000e829fbfe/content.htm
http://www.sapdevelopment.co.uk/dialog/dialoghome.htm
http://www.sap-img.com/
http://help.sap.com/saphelp_46c/helpdata/en/08/bef2dadb5311d1ad10080009b0fb56/content.htm
http://www.sapgenie.com/links/abap.htm
http://help.sap.com/saphelp_nw04/helpdata/en/c9/5472fc787f11d194c90000e8353423/frameset.htm
You can also check the transaction ABAPDOCU which gives you lot of sample programs.
Also you can see the below examples...
Go to se38 and give demodynpro and press F4.
YOu will get a list of demo module pool programs.
One more T-Code is ABAPDOCU.
YOu can find more examples there.
See the prgrams:
DEMO_DYNPRO_TABLE_CONTROL_1 Table Control with LOOP Statement
DEMO_DYNPRO_TABLE_CONTROL_2 Table Control with LOOP AT ITAB
http://www.geocities.com/ZSAPcHAT
http://www.allsaplinks.com/files/using_table_in_screen.pdf
REPORT ZBHMOD1 .
DATA:OKCODE1 LIKE SY-UCOMM,
OKCODE2 LIKE SY-UCOMM.
DATA:N1(10) TYPE N,N2(10) TYPE N,RES(12) TYPE N.
MODULE USER_COMMAND_1000 INPUT.
CASE OKCODE1.
WHEN 'NEXT'.
RES = N1 + N2.
SET SCREEN 1001.
WHEN 'CLEA'.
CLEAR:N1,N2.
WHEN 'BACK'.
SET SCREEN '0'.
ENDCASE.
ENDMODULE. " USER_COMMAND_1000 INPUT
MODULE STATUS_1000 OUTPUT.
SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR 'TIT1'.
ENDMODULE. " STATUS_1000 OUTPUT
MODULE USER_COMMAND_1001 INPUT.
CASE OKCODE2.
WHEN 'BACK'.
SET SCREEN 1000.
ENDCASE.
ENDMODULE. " USER_COMMAND_1001 INPUT
MODULE STATUS_1001 OUTPUT.
SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR 'TIT2'.
ENDMODULE. " STATUS_1001 OUTPUT
FLOW LOGIC:
PROCESS BEFORE OUTPUT.
MODULE STATUS_1000.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_1000.
PROCESS BEFORE OUTPUT.
MODULE STATUS_1001.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_1001.
2)
REPORT ZBHMOD2.
DATA: OKCODE1 TYPE SY-UCOMM,
OKCODE2 TYPE SY-UCOMM,
ENAME(10) TYPE C,
DNAME(10) TYPE C.
MODULE STATUS_1000 OUTPUT.
SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR 'TIT1'.
ENDMODULE. " STATUS_1000 OUTPUT
MODULE STATUS_1001 OUTPUT.
SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR 'TIT2'.
ENDMODULE. " STATUS_1001 OUTPUT
MODULE USER_COMMAND_1000 INPUT.
CASE OKCODE1.
WHEN 'BACK'.
SET SCREEN '0'.
WHEN 'NEXT'.
DNAME = ENAME.
SET SCREEN '1001'.
ENDCASE.
ENDMODULE. " USER_COMMAND_1000 INPUT
MODULE USER_COMMAND_1001 INPUT.
CASE OKCODE2.
WHEN 'BACK'.
SET SCREEN '1000'.
ENDCASE.
ENDMODULE. " USER_COMMAND_1001 INPUT
FORM ON_CTMENU_FORM USING ZDEMO1 TYPE REF TO CL_CTMENU.
CALL METHOD ZDEMO1->LOAD_GUI_STATUS
EXPORTING
PROGRAM = 'ZDEMO1'
STATUS = 'ZDEMO1'
MENU = ZDEMO1.
ENDFORM. " ON_CTMENU_FORM
FLOW LOGIC:
PROCESS BEFORE OUTPUT.
MODULE STATUS_1000.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_1000.
PROCESS BEFORE OUTPUT.
MODULE STATUS_1001.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_1001.
Every Screen has a pbo and a pai.
Screen elements are the textbox, buttons, radio buttons and check boxes .....
If we want to pass data from a abap program to a screen element, we have to create a variable with the name we have given in the screen.So whatever the value is present in that variable is reflected on to the screen element.
Here is an example :
Using subscreens and some of the screen elements
REPORT demo_dynpro_subscreens.
DATA: ok_code TYPE sy-ucomm,
save_ok TYPE sy-ucomm.
DATA: number1(4) TYPE n VALUE '0110',
number2(4) TYPE n VALUE '0130',
field(10) TYPE c, field1(10) TYPE c, field2(10) TYPE c.
CALL SCREEN 100.
MODULE status_100 OUTPUT.
SET PF-STATUS 'SCREEN_100'.
ENDMODULE.
MODULE fill_0110 OUTPUT.
field = 'Eingabe 1'(001).
ENDMODULE.
MODULE fill_0120 OUTPUT.
field = field1.
ENDMODULE.
MODULE fill_0130 OUTPUT.
field = 'Eingabe 2'(002).
ENDMODULE.
MODULE fill_0140 OUTPUT.
field = field2.
ENDMODULE.
MODULE cancel INPUT.
LEAVE PROGRAM.
ENDMODULE.
MODULE save_ok INPUT.
save_ok = ok_code.
CLEAR ok_code.
ENDMODULE.
MODULE user_command_0110 INPUT.
IF save_ok = 'OK1'.
number1 = '0120'.
field1 = field.
CLEAR field.
ENDIF.
ENDMODULE.
MODULE user_command_0130 INPUT.
IF save_ok = 'OK2'.
number2 = '0140'.
field2 = field.
CLEAR field.
ENDIF.
ENDMODULE.
MODULE user_command_100 INPUT.
CASE save_ok.
WHEN 'SUB1'.
number1 = '0110'.
WHEN 'SUB2'.
number1 = '0120'.
CLEAR field1.
WHEN 'SUB3'.
number2 = '0130'.
WHEN 'SUB4'.
number2 = '0140'.
CLEAR field2.
ENDCASE.
ENDMODULE.
flow logic for screen 100
PROCESS BEFORE OUTPUT.
MODULE STATUS_100.
CALL SUBSCREEN: AREA1 INCLUDING SY-REPID NUMBER1,
AREA2 INCLUDING SY-REPID NUMBER2.
PROCESS AFTER INPUT.
MODULE CANCEL AT EXIT-COMMAND.
MODULE SAVE_OK.
CALL SUBSCREEN: AREA1,
AREA2.
MODULE USER_COMMAND_100.
flow logic for screen 110
PROCESS BEFORE OUTPUT.
MODULE FILL_0110.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_0110.
flow logic for screen 120
PROCESS BEFORE OUTPUT.
MODULE FILL_0120.
PROCESS AFTER INPUT.
flow logic for screen 130
PROCESS BEFORE OUTPUT.
MODULE FILL_0130.
PROCESS AFTER INPUT.
MODULE USER_COMMAND_0130.
flow logic for screen 140
PROCESS BEFORE OUTPUT.
MODULE FILL_0140.
PROCESS AFTER INPUT.
Reward points if useful
Regards,
Priyanka. -
How to create tcode for modulepool program with selection screen?
hi,
How to create tcode for modulepool program with selection screen?
thanks,
sagarHi,
We need to goto SE80.
In our program we right click on object name and goto create
-> transaction. Enter the module pool program and screen number and save and activate.
Or by SE93 also we can create a transaction code for our program.
Hope ths helps.
plz reward if useful.
thanks,
dhanashri..
Edited by: Dhanashri Pawar on Jul 22, 2008 8:29 AM -
Variant NLFRS1 of program RFSSLD00 is not the current version
Hi,
I am getting a error message "Variant NLFRS1 of program RFSSLD00 is not the current version" when I tried to display the variant
Help me to solve the issue?
Thanks & Regards
Suresh KumarMahesh,
One more thing to add, if the variant is changed purposefully,
Go to
SE38
For the Program,
1. select the variant 'RADIO BUTTON'
2. Click 'Display'.
3. On the Menu, Click 'Variants'.
4. Click on 'Adjust'.
5. Now, Click the 'Execute' button.
Execute the Program with the Variant now.
This should resolve the isssue. -
How to create a variant for a program without selection screen
Hi All,
I've created one program which takes the data from 30 tables and loads into one final table.
This program is already moved to Production.
But while creating variant it's not allowing, since the program doesn't have the selection screen.
Is there anyway where I can create a variant in production without selection screen directly as the program code is already moved to production.
Thank You,
Regards,
Karthik.ChHi ,
Are you running this program in a process chain??
Maybe you are looking for
-
Is there any way of creating separate I.d.'s under 1 apple I.d.? My kids are too young to have there own apple I.d. And then they wouldn't be able to access all the music and apps we have purchased .....or would they. I'm am finding this confusing
-
Uk charger for us hp pro book 4545s
I have a us hp pro book 4545s. I am moving to the uk. I was wondering if I could buy a uk charger for my computer and use that instead of using a converter. Will that fry my computer though? This question was solved. View Solution.
-
Hello Experts, we wan to create some custom logic to Remove some orders from campaign. For this we have created a function and removing the order from campaign in /SAPAPO/CDPS_FDISHEU->BEFORE method. but the changes which i am doing they get save imm
-
Hi all, Has anyone succeeded in getting a Gateway with ContentRouting up and running? This product looks very promising but so far it NOT delivering what it promises Mark
-
Multiple use of a shared variable - buffers?
Hi all, I have an application on a RT target that measured data (around 60 variables stored in a big cluster) in a TCL, sends it via RT-FIFO (a modified U8-Array buffer that contains the data converted into string and then flattened to U8-Array) to