General discussion

Locked

Access 97 form troubles

By Logic2 Tech ·
In a form, in 'add mode' I want a bound text box to have a default value as follows:

Max[textField]+1

textField contains only numbers.
Add mode doesn't cycle records(for me anyway.
If the value is obtained from another form, default value isset before the other form has finished calculating.
A 'set value' macro doesn't want to work on my 'bound' text box.
textField has values from another form also, can't be auto number.
Database tables are in a MDE from the previous programmer who has conveniently lost all source code and we need to make a whole new dbase system for the changes we're incorporating.
This form will determine the next 'job number' and allow manipulation of accounts to describe what the jobNum is.

This conversation is currently closed to new comments.

4 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

Access 97 form troubles

by rraheb In reply to Access 97 form troubles

I don't think I fully understand your problem, but as far as I understand I guess you can put this calculated value as the default value for this field in the form. You'll find this in the text box properties.

Then you can either allow the userto edit this default value or not by setting the locked property to either no or yes.

Hope this is helpful...

Contact me for clarifications...

-Rafik

Collapse -

Access 97 form troubles

by Logic2 Tech In reply to Access 97 form troubles

View my update of this question please...Now worth more points.

Collapse -

Access 97 form troubles

by spammy In reply to Access 97 form troubles

If I understand your message correctly, it looks like what you need is a Domain Aggregate function, like this:

=DMax("[FieldName]","TableName")+1

Add that bit of code to your default property and you should get what you want every time.

Good luck!

-Dori Horn
DazzTec Computer Control

Collapse -

Access 97 form troubles

by Logic2 Tech In reply to Access 97 form troubles

Please view my update on this question worth more points now...

Back to Web Development Forum
4 total posts (Page 1 of 1)  

Software Forums