KP_SoCal
asked on
Use a message box to change to default value of a control.
I'm looking for a block of code that allows an end-user to permanently change the default value of a form control Me.txtName via whatever value is typed in an input box.
I've searched high and low on the internet, and have not found anything that would accomplish this. As soon as the form is closed, the default value reverts back to what I manually set in the default properties window.
Any help is greatly appreciated.
I've searched high and low on the internet, and have not found anything that would accomplish this. As soon as the form is closed, the default value reverts back to what I manually set in the default properties window.
Any help is greatly appreciated.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
In Excel you can use Application.Names.Add and the Evaluate method to store and recall values within the application, but assuming that that doesn't apply to Access then depending on the OS you can save and recall the value from an Access table, ini file, regular text file or the Registry. Since this is Access the Access table seems to be the natural choice.
ASKER
I didn't think it was possible either without going in to Design View. I thank you both for pointing me in the right direction on this.
Just curious ... and this is certainly not a big deal of any kind, but ... the Accepted Answer talks about Excel ... the concurs with what I said about using a Table ... so, just wondering why you didn't reverse Accepted and Assisted ?
mx
mx
ASKER
Sorry, I didn't even notice their was an "Accepted" and "Assisted". My mistake.
Yes I agree. You should get most if not all of the points since, while I didn't notice it when I posted, you were first.
'Request Attention' and the moderators will reopen the question.
ASKER
Ok, I'm requesting the moderator to open. My apologies for the mix-up.
No need to reopen ...
mx
mx
And my comment had nothing to do with points :-)