Hello all
I am doing some work on a database coded by someone else. I have come across this unnusual way (to me) of using errors:
A form is opened using a filter to restrict the records. In the on-current event of this form, there is code that checks and inserts a value in a text box. Fine so far.
The odd bit is that if the filter results in no records being displayed, Access throws up an error No 94, Invalid use of Null. My predeccessor has simply got around this by adding error handling which says 'If Err = 94...go to a new record instead'. My question is, is this good practise or is it likely to cause problems? It does seem to work OK...
Thanks Nigel
Didn't someone say work is supposed to be fun? They didn't have computers then I guess....
I am doing some work on a database coded by someone else. I have come across this unnusual way (to me) of using errors:
A form is opened using a filter to restrict the records. In the on-current event of this form, there is code that checks and inserts a value in a text box. Fine so far.
The odd bit is that if the filter results in no records being displayed, Access throws up an error No 94, Invalid use of Null. My predeccessor has simply got around this by adding error handling which says 'If Err = 94...go to a new record instead'. My question is, is this good practise or is it likely to cause problems? It does seem to work OK...
Thanks Nigel
Didn't someone say work is supposed to be fun? They didn't have computers then I guess....