‎2011 Sep 14 12:00 PM
Dear Friend,
according to my requirement i wanted call table maintenance view 2nd screen.(data entering screen)
i have used BDC for that and call that bdc in the program.
it works
now problem is when i click on the back button (standard) it comes to maintenance view 1st screen (list view)
so i want to come back to main selection screen
my code is follows
DATA: BDCDATA LIKE BDCDATA OCCURS 0 WITH HEADER LINE.
*
start-of-selection.
*
*
perform bdc_dynpro using 'SAPMSVMA' '0100'.
perform bdc_field using 'BDC_CURSOR' 'VIEWNAME'.
perform bdc_field using 'BDC_OKCODE' '=UPD'.
perform bdc_field using 'VIEWNAME' 'ZSOD_APPRV_REG'.
perform bdc_field using 'VIMDYNFLDS-LTD_DTA_NO' 'X'.
perform bdc_dynpro using 'SAPLZSOD_APPRV_REG' '0001'.
perform bdc_field using 'BDC_CURSOR' 'ZSOD_APPRV_REG-NAME_TEXT(01)'.
perform bdc_field using 'BDC_OKCODE' '=NEWL'.
*
call TRANSACTION 'SM30' using bdcdata MODE 'E' UPDATE 'S' .
*
FORM BDC_DYNPRO USING PROGRAM DYNPRO.
CLEAR BDCDATA.
BDCDATA-PROGRAM = PROGRAM.
BDCDATA-DYNPRO = DYNPRO.
BDCDATA-DYNBEGIN = 'X'.
APPEND BDCDATA.
‎2011 Sep 15 8:29 AM
HI,
I am not sure if i understood your problem properly, So correct me if I am..
First of all, instead of directly calling sm30 from your program, goto se93 and create a tcode ( parameter transaction ) for your table maintenance view. For this you have to give tcode as Sm30, and check the check box 'skip first screen' and below, in parameters, select viewname and give the name of your view and then update with value X.
Now call this Tcode form your program..
Will this satisfy your requirement?
‎2011 Sep 14 12:06 PM
Hi,
I guess you can do in this way.Try to catch the function code of that button and write your code and call according to that.
Regards,
Madhu.
‎2011 Sep 15 5:26 AM
dear Madhu
how can i apply to my code
i just try to find function code by using break point after call transaction
but it triggered after finished the SM30.
‎2011 Sep 15 5:31 AM
Hi Nelson
I am guessing in this way.
perform bdc_dynpro using 'SAPMSVMA' '0100'.
perform bdc_field using 'BDC_CURSOR' 'VIEWNAME'.
perform bdc_field using 'BDC_OKCODE' '=UPD'
This is the code of your recording.In the same way bdc_okcode for that button , press f1 and see.Here check that screen number ,program name and see.
Regards,
Madhu.
‎2011 Sep 15 5:47 AM
Hi Madhu,
actually i cant get what you are telling and what i want to do, please describe
‎2011 Sep 15 5:51 AM
Hi Nelson,
+now problem is when i click on the back button (standard) it comes to maintenance view 1st screen (list view)
so i want to come back to main selection screen+
You want to come to the initial screen.Once your data filling is over in the screen you want to come to initial screen.What i am telling read the screen no,program and keep that code.
Regards,
Madhu.
‎2011 Sep 15 6:13 AM
hi write
when you press back button or on exit-command.
set screen 0
leave screen.
‎2011 Sep 15 6:30 AM
Madhu, I don't think it works, cuz it will go to maintenance screen and come back immediately before we enter any data. I faced the same problem and could never figure out a solution. If some one has a solution that worked it would be great!!.
‎2011 Sep 15 6:37 AM
hi Madhu,
i have selection screen and one command button
when i click on the Command button only call maintenance view screen 2(data enter screen)
so when i click on the back button i want to go to my selection screen but in current situation back button come to maintenance view screen 1 and if i click back again it come to sm30 screen when i click again only comes to selection screen
i want to skip these steps.
‎2011 Sep 15 7:24 AM
Nelson, Exit button (yellow) skips the screen 1 and comes back to the original program but it's not a solution.
‎2011 Sep 14 12:17 PM
Hi Nelson,
Try using Leave to Screen 0 or call screen statements after the BDC.
Amuktha
‎2011 Sep 15 8:29 AM
HI,
I am not sure if i understood your problem properly, So correct me if I am..
First of all, instead of directly calling sm30 from your program, goto se93 and create a tcode ( parameter transaction ) for your table maintenance view. For this you have to give tcode as Sm30, and check the check box 'skip first screen' and below, in parameters, select viewname and give the name of your view and then update with value X.
Now call this Tcode form your program..
Will this satisfy your requirement?
‎2011 Sep 15 9:36 AM
hi
no friend when i call as t code it come to screen 1 (list view)
i want call screen 2 directly
‎2011 Sep 15 9:58 AM
have you recorded till you reach screen 2 ?? I mean.. if you run ur recording with Display no screen ( background processing mode) does it stop at teh second screen ?
‎2011 Sep 15 10:04 AM
‎2011 Sep 15 10:22 AM
OK.. If your BDC reaches the correct screen while running from SHDB with mode 'E', it should/ will stop at that position when you assign a t-code to it.. Skip first screen parameter is used only to avoid the sm30 screen while execution..
If that solution does not work, can you try if you can take the main program,, and change the Gui status.. In Back there.. try giving SET SCREEN 0. ..
‎2011 Sep 15 10:33 AM
O sorry.. I forgot to mention the last part!!! after you create the Tcode.... record this Tcode using SHDB and record TEH nEW eNTRIES bUTTON... Now use call transaction 'tcode' .
‎2011 Sep 15 10:54 AM
‎2011 Sep 15 11:32 AM
Hi Suzie,
dear actually didn't get with you, can you please describe little bit
‎2011 Sep 15 12:03 PM
Hi
i got what u point dear,
but i create tcode with call view
and i use it in BDC with call transaction
when i run it it works
but when i press the back button it come s to previous screen(list view)
‎2011 Sep 15 12:03 PM
OK.. I ll try..
First create a parameter transaction with your new view and make sure Skip first screen check box is checked ( for which the table maintenance generator is there). Also give update = 'X' in parameters along with the view name.
Now record this new transaction till the point of new entries.
Now call this code in your program.
Now it will not go to the sm30 initial screen when you click back...
But it might go to the list of entries .. If you want to skip that too, you have to change the GUi status back option..
try and tell me
‎2011 Sep 15 12:18 PM
Ok.. Now that you have a program . Take this program and take its gui status.. change the back funcion code and write set screen 0 . in it.
‎2011 Sep 16 4:42 AM
Hi Dear,
actually problem is..
i create a program for call Tcode in BDC
where i find function code
its in background process when i execute from program it runs when i press back it comes to list if i press back again only comes to program
‎2011 Sep 16 5:29 AM
Hey.. does it go to teh first list even when you click on teh Yellow (EXIT) button >
‎2011 Sep 16 6:11 AM
Try this.. from your table maintenance screen, you can take that particular screen in change mode rite?? In the flow logic fro that screen, write a new module for exit command.. Copy the contents of the current at exit command module, and make teh necesary changes tehre
‎2011 Sep 28 10:46 AM
I'll come back to this issue,
I'm using LEAVE TO SCREEN 0 with back button, but it leaves one screen, I want to skip two screens.
Please tell me how can I do this?
‎2013 Mar 20 9:05 AM