Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Selection on a scrolling panel

Status
Not open for further replies.

tpms2000

Programmer
Jan 20, 2003
19
EU
Sample scrolling panel problem:

Sel Dataset name
_ level1.level2.a
Y level1.level2.b
Y level1.level2.c
_ level1.level2.d
I select .b and .c for some action.

Situation 1
If there's no problem (i.e. no error message generated) then I should see:
Sel Dataset name
_ level1.level2.a
_ level1.level2.d
as .b and .c are the subject of a TBDELETE

Situation 2
If there's a problem with .b then I should see:
Sel Dataset name
_ level1.level2.a
Y level1.level2.b
Y level1.level2.c
_ level1.level2.d

Situation 3
If there's a problem with .c then I should see:
Sel Dataset name
_ level1.level2.a
Y level1.level2.c
_ level1.level2.d

At the moment everything in the Sel column is blank in Situation 2 and 3 rather than the Selections keeping their value of Y
 
You are probably in a loop on 'ztdsels'. As the loop ends, there may be a statement wiping out the action-code field:
Code:
      sel = ''
[\code]
 
I thought of that just after I posted this. So I did delete that line, and now all the selections have a Y in them instead of only those I actually selected.
 
The way I do it is to create a field for the SEL in the table I create. Then modify it with a TBMOD just for the table entry that the action was against when action is complete.

It seems to do the job albeit a little cludgy
 
Thanks - I tried this but run into more problems. Does anyone know of any decent online documentation for this - outside of the official IBM stuff?
The problems I encounter are
1) The panel ensures that only Y is a valid selection choice. If I try to select with, e.g. X, then, after the error message displays, I delete the X, it still thinks it's selected and gives me an error message.
2) If I don't TBPUT (the table has no keys so TBMOD not used) then the cursor is correctly positioned at the selection in error. If I do TBPUT (to retain the selection as you suggested) the cursor goes to the command line despite the values in CRSPOS and CRSROW not changing. I tried refreshing the table by moving the table to a stem, TBENDing the table then recreating with data from the stem. But this still does not position the cursor on the Y selection if an error message is generated.
I think I need a scrolling panel course.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top