Referencing ad-hoc tables on forms..

  • Thread starter Thread starter every1luvsVB via AccessMonster.com
  • Start date Start date
E

every1luvsVB via AccessMonster.com

Hi there,

I have a table i use solely for 'environment variables' i.e. image paths etc.
(i overwrite the one record all the time by setting isdirty flag to false
prior to each save..) -only problem now is when i try to 'use' the fields of
this table on a form that doesnt reference this table or doesnt reference any
table..

-is there a way that i can reference this 'lone' table on a form / in code if
(a) the form does not use this table as its record source or (b) the form
does not have any record source at all??

i hope that is not too confusing. thanks for any assistance.
 
every1luvsVB said:
(i overwrite the one record all the time by setting isdirty flag to false
prior to each save..)

Setting IsDirty to false, actually saves the dirtied record.

But that does not, by itself, restrict the table to just one record.

HTH,
TC (MVP Access)
http://tc2.atspace.com
 
Thanks for the advice guys -is much appreciated.

TC, I don't doubt your advice below, but it's working fine, i.e. i have
something like:

....
If Me.isDirty = True Then
Me.isDirty = False
End If
....
....
[standard save record routine..]
....

-and it keeps saving over the one record, which is just what i wanted it to
do. would u know why?

cheers.
 
Access will /always/ save "over the existing record", unless you
explicitly create a new one. So I suspect that your IsDirty() code, is
not really stopping anything :-)

Cheers,
TC (MVP Access)
http://tc2.atspace.com
 
TC said:
Access will /always/ save "over the existing record", unless you
explicitly create a new one. So I suspect that your IsDirty() code, is
not really stopping anything :-)

Cheers,
TC (MVP Access)
http://tc2.atspace.com


Dammit TC you are correct -well i dont know why its working.. thanks for
advice.
 
Back
Top