Slave Screens - Altering data prior to display
Pickering, John (NORBORD)
PICKERIJ@norbord.com
Tue, 22 Feb 2000 12:48:20 -0500
Carol
My tiny brain just kicked in with another idea!
I know you'll choke at the idea of changing all those date items and
routines but please think about this. Redefine all the dates in the
dictionary as below. Note the inclusion of the separator characters on year
and month. I might even make the individual date components zoned unsigned
and put a signif on the picture so they'd always be full size.
Element CAROL-DATE &
Character Size 8 &
Heading "Carol" &
Label "Carol date"
; picture for those occaisions when ccyy-mm-dd is ok
Picture "^^^^-^^-^^"
Element CAROL-CCYY &
Character Size 4 &
Heading "Carol^ccyyy" &
Label "Carol ccyy"
Picture "-^^^^"
Element CAROL-MM &
Character Size 2 &
Heading "Carol^mm" &
Label "Carol mm"
Picture "^^"
Element CAROL-DD &
Character Size 2 &
Heading "Carol^dd" &
Label "Carol dd"
Picture "-^^"
Item CAROL-DATE Datatype Character Size 8 Create
Begin Structure
Item CAROL-CCYY Datatype Character Size 4
Item CAROL-MM Datatype Character Size 2
Item CAROL-DD Datatype Character Size 2
End Structure
Then in my screens I would use the following to display and enter any date.
align (1,4,15) (,,17) (,,20)
field carol-mm autonext label "Carol date"
field carol-dd autonext
field carol-ccyy
The autonext fools the user into thinking that the adjacent fields are
really all one item. You could then more easily edit the individual parts of
the date. For example the mm part is simply: 'values 1 to 12, 99' assuming a
numeric item. You might get fancy with the dd so that April can't have 31
days and you can easily apply the century to a 2 digit entry in ccyy. Then
no junk in the postfind and no junk in the preupdate. And all of the edit
stuff can be in a use file called directly from the input or edit procedure
for the individual components.
procedure edit carol-mm
begin
use editmm.source nol
end
Quiz reports simply print the 3 components with tabs to get them right next
to each other.
And you can probably implement this slowly as time permits. Redefine the
date item in the dictionary and then visit all the places that date is used.
Do them one by one!
Sigh, so many good ideas, so little time :-(
Regards,
JWP
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
Subscribe: "subscribe powerh-l" in message body to majordomo@lists.swau.edu
Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
This list is closed, thus to post to the list, you must be a subscriber.