2006 Nov 24 7:10 AM
1)what is diff between set screen and call screen
2)when to use set screen and when to use call screen
3)Is leave screen 0 and back button functionality same ?
1)what is diff between set screen and call screen
2)when to use set screen and when to use call screen
3)Is leave screen 0 and back button functionality same ?
2006 Nov 24 7:11 AM
hi,
chk this.
CALL SCREEN 200
If we write this statement in screen 100 ,it will goto screen 200 and it will retain screen 100(ie u can come back)
and moreover u have options using this
CALL SCREEN 200 STARTING AT x1 y1 ENDING AT x2 y2
SET SCREEN 200
with the above statement , it will goto screen 200 and screen 100 no more remains
And no additional options for this
LEAVE SCREEN
Leaves the current screen and processes the next screen.
LEAVE TO SCREEN 200
it leaves the current screen and processes screen 200
Rgds
Anver
2006 Nov 24 7:18 AM
hi,
1)what is diff between set screen and call screen
2)when to use set screen and when to use call screen
If you use the call screen option then control moves from the calling screen to called screen and after processing screen control again comes back into the calling screen to process the remaining code
where as if you use set screen then control moves from calling screen to called screen and process the called screen and it will not come back again into the calling screen it reamains there only.
Regards,
Naveen
2006 Nov 24 7:21 AM
Hi,
Here are your answers -
1. CALL SCREEN will take effect immediately. SET SCREEN will take effect only at the end of the event block (usually PAI).
2. Depends on the requirement. Either of the two statements can be used to achieve the same result (if the logic is adapted accordingly).
3. In general, yes.
Regards,
Anand Mandalika.
2006 Nov 24 7:28 AM
Hi Mahya,
Every screen has a next screen sequence. if you see the properties of the screen, you will see a field called "Next Screen". You set this and you would have set the next screen statically at design time. what the next screen does is, once the PAI of current screen is complete (100), automatically goes to the next screen 200, on pressing an enter.
when you say SET SCREEN 300, what you have done is changed this sequence. so instead of calling screen 200, it would call now screen 300. as Anand said, this will happen only after the PAI of 100 is completed.
A call screen is different, in the sense, it does not alter the next screen sequences at all. Instead, when you say call screen 300, from 100, it goes IMMEDIATELY to 300. You have the provision to come back to screen 100, and then when PAI of 100 is completed, you will still go to screen 200, since 200 was the next screen for screen 100. as i said, the next screen is not altered by the call screen.
3. leave to screen 0 simply navigates back to the caller of a screen. Yes, it is like a back button.
hope this answers ur question.
Pls reward suitable points.
Rgds,
Prabhu.
2006 Nov 24 1:58 PM
Hi,
1. With SET SCREEN the current screen simply specifies the next screen in the chain , control branches to this next screen as soon as the current screen has been processed .Return from next screen to current screen is not automatic .It does not interrupt processing of the current screen. If we want to branch to the next screen without finishing the current one, use LEAVE SCREEN .
2. With CALL SCREEN , the current screen is suspended , and a next screen is called .The called can then return to the suspended screen with the statement LEAVE SCREEN TO SCREEN 0.
Regards,
Praveen
2006 Nov 24 3:06 PM
hi,
upto my knowledge both are same,either you can use
set screen 100.
call screen.
or
leave to screen 100.
regards,
sowjanya.
2006 Nov 25 11:50 AM
1. Set Screen statement overrides the NEXT SCREEN attribute of screen dynamically while call screen call the new screen,
the diffrence between set screen and call screen is that, when set screen is executed, the control never come backs to current screen while in call screen the after completion of called screen control comes back to current/calling screen's statement.(statement preceeding to call statement.)
2.when you don't want ot come back to the calling screen use set screen.
better example is when you want some value from the called screen use screen, like pop up in when after pressing of enter the valu should be available in the main program.
3. when you are using the call screen and you wanted to go back to the parent screen we uses the set screen 0.
set screen puts the control to the parent screen.
so we can say that set screen and back button functionality is same.
2006 Nov 27 8:37 AM
The difference is as follows....
For ex ,
we call from screen 100..
call screen '200'.
and in the screen 200 after all the processing is completed and when u give the statement set screen ' 0 '.and when it encounters leave scree.
the process control will be give to the next line after call screen 200 statement ..
so ..if u have any further logic to be executed in the screen 100 after the call screen 200 , statement this can be handy ...
set screen 'nnnn' ... is used to temporarily overrite the next screen value and the control will be passed to the next screen when the leave screen statement is encounterd.
2006 Nov 27 12:29 PM
1. With SET SCREEN the current screen simply specifies the next screen in the chain , control branches to this next screen as sonn as th e current screen has been processed .Return from next screen to current screen is not automatic .It does not interrupt processing of the current screen.If we want to branch to the next screen without finishing the current one ,use LEAVE SCREEN.
With CALL SCREEN , the current (calling) chain is suspended , and a next screen (screen chain) is called .The called can then return to the suspended chain with the statement LEAVE SCREEN TO SCREEN 0 .Sometime we might want to let an user call a pop up screen from the main application screen to let him enter secondary information.After they have completed their enteries, the users should be able to close the popup and return directly to the place where they left off in the main screen.Here comes CALL SCREEN into picture .This statement lets us insert such a sequence intp the current one.
2. Set scrren means it will not come back to Previous screen.
call screen we can use to come back toPrevious screen.
3. it like an back button.
Point.
2006 Nov 28 4:59 AM
hi,
Hope this answers your questions. Reward if useful.
1)what is diff between set screen and call screen
>> Set screen does not interrupt the current processing of the screen. Set screen s basically used for dynamically defining the next screeen(static method is the one in which you specify next screen in screen attributes, while defining it).
2)when to use set screen and when to use call screen
>> As I said above use set screen if you want to define next screen dynamically, i.e. the processing of current screen will be completed and the screen set through set screen will be called, but if you want to quit the current screen right away and go to the screen you want use call screen.
3)Is leave screen 0 and back button functionality same ?
>> Not really Leave to screen will go to originator of the transaction (It could be previous screen also in which the functionality is same as back). But if there are 3 screens and you're in last, the LEAVE TO SCREEN 0 will take to first screen. Back to second screen.
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |