unchangeable fields in a form

antonyx

Arsenal Supporter
Local time
Today, 07:45
Joined
Jan 7, 2005
Messages
556
hi..

i have a justified form..

with 8 fields (coming from three tables)..

basically when my user enters records.. i want 2 of the fields to not change..

these two fields are Job Date and Notes..

eg.

the user opens the form..

they enter a date.

all records entered will share that date..

also, at the bottom of the form.. i want a notes tab.. it might be possible to put the date in the form header and the notes in the form footer but im not to sure..

see the pictures below..
 
Last edited:
let me simplify the request as i need to get things moving..

if you have a form.. how can you set a field to keep the first value you enter in it while the other fields and records are populated..

so you are entering taxi jobs for a specific day..
and you are entering information from a daily booking sheet..

rather then enter the jobdate field as today for every record.. i would want to set the job date to todays date.. and then keep it set for all the records i enter ..

anyone know how to do this?

bare in mind the jobs wont always be entered on the exact day.. so i cant use something like jobdate=Today() or nothing like that..

i would need to manually enter the date of my choosing.. and then enter records for that date.
 
Last edited:
this is normalization

if you want data not to change it implies that you are loking at a subset of the data

therefore it sounds like you should have one form for the job, including job date, notes and any other job specific info.

then you need a sub-form linked to this to show repeating data associated with this job eg materials/labour used etc

------------------------
if you put it all on one form, then you still need to filter the single job somehow, otherwise you will see the details of all jobs.
 
ok.. i realise what you say...


my database structure is normalised.. maybe not to the extent where its perfect. but its enough..

the job date and job time and job details all belong in the same table because they are all unique to that job and are all known by knowing the job id..

you must understand that there will be other job input forms also without this feature

all i want to know is how i can ensure a field.. just in one particualr form, can be set to a specific value chosen by the user on opening of the form.. and then remain as that value.. for that field.. for all the subsequent records entered..

is there now way i can add an event to the form open that says.. enter the date

and they type 06/06/06 and then that value remains in the jobdate field, for every record that is entered, until the form is closed?
 
make the field locked, enabled - which will prevent a user editing the value.

Then save the required date in a variable in a forms module, and probably in the current event you can do

if me.newrecord then
datefield = savedvalue
end if
 
when you say form module.. couldnt i just use your method.. with a message alert.. saying what is the date.. and then enter a date.. and that value is set to savedvalue?
 
i mean the code behind the form (the form's module) where you enter code caused by the various events.

Is that what you are using?
 

Users who are viewing this thread

Back
Top Bottom