Re: Enable/Disable Field in 4gl code

Savvas Petrou <[email protected]>
Newsgroups gmane.comp.lang.4gl.fourjs.user
Message-ID <[email protected]>
Everett,

Thanks for your reply!

I believe i have stated my question wrongly.

Firstly is there a built in function that allows a certain field to be
disabled or enabled?
I am guessing setfgl_field_attribute(..,..,..,ENABLE OR DISABLE).

Secondly, the field i want to disable firstly the user is allowed to input
data.
After the user inputs data some validation checkes are performed and if
valid then the cursor moves to the next field. And now i want to disable the
field
so the user is not allowed to change the value of the field.

Thanks
Savvas Petrou




----- Original Message ----- 
From: "Everett Mills" <[email protected]>
To: <[email protected]>
Sent: Friday, January 07, 2005 5:06 PM
Subject: RE: [fourjs-users] Enable/Disable Field in 4gl code


Savvas,

When you want the field to be disabled, try this:

    LET field_flag = -1 --this will disable the field, leave it null and the
field will be useable

    INPUT foo FROM bar.*
        BEFORE FIELD myfield
            IF ( field_flag = -1 ) THEN
                DISPLAY myvariable TO myfield
                NEXT FIELD myotherfield
            END IF

    END INPUT


    --EEM





-----Original Message-----
From: Savvas Petrou [mailto:[email protected]]
Sent: Friday, January 07, 2005 6:03 AM
To: [email protected]
Subject: [fourjs-users] Enable/Disable Field in 4gl code

Dear Sirs,

I would like to know how to disable or enable a certain field exclusively in
my 4gl code.

I have tried the following in my AFTER FIELD clause

DISPLAY myvariable TO myformvariable
Then i have tried to set ATTRIBUTE(NOENTRY) to myformvariable
but with no success.


Thanks
Savvas Petrou
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.