Re: Informix Ring Menu - Before Menu Option
Posted in 1996
Ken McCoy wrote: > > Here is the problem . . . > 1.) You have a great 4gl menu with a Next and an Update option on. > 2.) A user hits the Next option until the last record in the set is > reached . The user selects the Delete option from the menu and > deletes the last record. > 3.) Everything is cool at this point. On the delete, we try to get the > next record. We check the status. We know we are at the last record. > So, we clear the form and pop up a message telling the user that there > are no more records to be found. > 4.) THE PROBLEM: The update and Delete options still display on the > Menu. If the user chooses these options it will try to execute > the code associated with these options and generate Nasty error > messages. If you detect no records after a delete then use HIDE OPTION... This may or may not require the setting of flags. If you delete the last record, you should display the previous record in order not to confuse the poor old user. If you delete the VERY last record then you should probably exit the option altogether, again in order not to confuse the user. Cheers, -- Mark. +-------------------------------------------------------------------------+ |Mark D. Stock - The West Solutions Group http://www.west.co.za | | | |mailto:marks@west.co.za +------------------------------------------------+ |Tel: +27 11 803 2151 |If it doesn't work... force it! | |Fax: +27 11 803 2189 |If it breaks... it needed replacing anyway! | |Cell: +27 83 250 2325 |Well, that's how I code anyway! | +------------------------+------------------------------------------------+