Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Want to creat a button that has to be clicked to edit an entry...

Status
Not open for further replies.

fictionwelive

Technical User
Mar 4, 2005
7
US
I'm building an inventory database for my place of employment, and when entering inventory, you enter the Serial Number and Customer it is for on the form, and also the date recieved. Then on the SubForm, the Serial Number is already populated according to what you put in above it. Then you can change where the piece of equipment actually is (it could be in house, or it might have been brought to another restaurant on an emergency service call.) Then you change the status of the product (staging, needs RMA, Healthy, etc)

When scrolling through the entries through the form, however, I noticed if you accidentally change a digit in a previous entries Serial Number, it doesnt need to be saved, it becomes permanent if you don't notice it.

I want buttons on the bottom of the forms:
Add Entry, Edit Entry, and Save Entry.

I want them to be fully functional, the only way you can add a new entry is by clicking the Add Entry button, and the only way you can Edit a previous entry is by finding it and then clicking Edit, and then Saving it.

How possible is this? Thanks. If you need more info, let me know.
 
Sometimes I Lock all controls on my form and only unlock them for editing when a command button is actioned.

me.txtfield.Locked=true

Set all controls in the On current/Open events to locked and then unlock them in the OnClick event of the command button when required for editing.

me.txtfield.Locked=false

You can then lock them again in the AfterUpdate event

Its a bit messy but works.



If IT ain’t working Binnit and Reboot
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top