Re: Skip 4gl form field
Posted in 2013
Can you show an aexample of you code? -------------------------------------------------------------------- Rodney Sheppard Software Engineer - Development Manager Trans-Mit Pty. Ltd. 7 Wendy Court Hampton Park, Vic 3976, Australia Phone... +61 3 87878744 Fax.........+61 3 87875722 Email...... rod@transmit.com.au Web....... www.transmit.com.au -------------------------------------------------------------------- __________________________________________________ ----- Original Message ----- From: Jonathan Leffler To: Rodney Sheppard Cc: Informix List - IIUG Sent: Thursday, May 09, 2013 12:16 AM Subject: Re: Skip 4gl form field On Wed, May 8, 2013 at 2:02 AM, Rodney Sheppard <rod@transmit.com.au> wrote: to skip input fields, I have used code like... before field voicemail IF GET_FLDBUF(site) = "UCP" THEN IF fgl_lastkey() = fgl_keyval("DOWN") OR fgl_lastkey() = fgl_keyval("TAB") OR fgl_lastkey() = fgl_keyval("NEXT") OR fgl_lastkey() = fgl_keyval("RIGHT") THEN NEXT FIELD firstinit END IF IF fgl_lastkey() = fgl_keyval("UP") OR fgl_lastkey() = fgl_keyval("PREVIOUS") OR fgl_lastkey() = fgl_keyval("LEFT") THEN NEXT FIELD pager END IF END IF Is tere a way to programmatically set a field attribute to NO INPUT ? ie. something like FGL_FORMFIELD_SETOPTION() If the code should never enter the field, you can set the NOENTRY attribute in the form. There isn't a way to change the NOENTRY status of a field at runtime. I have coded INPUT statements such that if a field needs to be skipped conditionally, it can be skipped (and it handles go backwards or forwards past the field). The net result is not as dissimilar from what you wrote as all that, though it was in generated I4GL that used different techniques in detail. -- Jonathan Leffler <jonathan.leffler@gmail.com> #include <disclaimer.h> Guardian of DBD::Informix - v2013.0118 - http://dbi.perl.org "Blessed are we who can laugh at ourselves, for we shall never cease to be amused."