When I scroll to the next record in an Access form, whatever field I am in gets highlighted once scrolled to the next record. How do I prevent the highlight of the entire field?
Users are having issues where they are accidentally deleting with one click because the entire field is highlighted.
You will find the behaviour set under Options, Behaviour Entering Field.
See also: http://msdn.microsoft.com/en-us/library/aa172326(v=office.11).aspx
Related
I have one main form with a subform and two date text boxes. The subform has been connected to the query with a date value column. I put criteria in query Between [Forms]![frm_mainform]![txt_from] And [Forms]![frm_mainform]![txt_to]. Also, both text boxes have Default Value set as =DateAdd("d";-30;Date()) and =DateAdd("d";30;Date()).
So, it works fine until I close the document and reopen it. After that subform doesn't recognize text boxes and lanch me entry boxes for both values.
Data entry form pic
After I change just one letter in Name it works again, and when I close the document again it lost it again.
Is anyone familiar with this behavior?
I have put Me.Refresh on Form_Load() event and it fixed it.
Still, I don't know what causes such behavior.
When I tab through records in my (datasheet) form, the tab key behavior is as expected; Focus moves to the next field, and then at the end of the fields moves to the next record. In forms where I have master-child subdatasheets, when the subdatasheet isn't expanded and the user tabs past the end of a record, focus moves to the next record. This is good / what I want. When a subdatasheet is expanded and the user tabs past the end of the master record, focus moves to the first field in the child subdatasheet. Again this is good / what I want.
What happens on the next tab key press is my issue. Rather than moving focus to the next field in the subdatasheet, focus goes straight to the next record in the master datasheet. I expect and want focus to go to the next field in the subdatasheet.
I have been playing with the tabstops and cycle properties on both the main form, subform, and subform control within the main form, and cannot come to a configuration where I get the behavior I desire.
Solved this now and thought I should log it here. Was a pretty stupid problem caused by an oversight on my part.
Basically, all of the controls on my subdatasheet were being set to locked and tabstop = false, in a procedure I have to apply control settings by control name. So I'd actually made those settings a while ago, forgotten, and then assumed that the user should be able to tab through them.
Obviously Access was hitting the subdatasheet control, going "no controls available to tab through here", and so immediately exiting the subdatasheet control.
When I was trying in code to set focus to any of the controls, the reserved error 2950 must've been because the controls weren't tab-stoppable.
I currently have a form in access which has text boxes which refreshes itself every time you click on it. I am assuming that access has a dynamic way of updating the tables, ie as soon as you move the cursor away from the text box, it updates the tables. Is there any way of making this static ie. I should have a button which after clicking updates a set of text boxes into the table. Although this is not a feature which is desired, I am planning to use this to prevent multiple users corrupting the data in the table.
What you're asking for is standard behavior... The record will not be saved until the record has lost focus, rather than the field. If your form is saving after each field loses focus (desired in some applications) it has been set up that way (probably with an OnChanged event on the textbox).
I'm fairly new to microsoft access and i'm currently designing a database for my company but I'm having some trouble trying to get the tab control to work properly. The problem is whenever it navigates through all the pages, when it reaches the last field to fill in, it goes to the next record but stays in the last page, it doesn't 'reset' back to the first page so it follows a logical order.
HansUp offered a good suggestion in his comment, but you may not want to unconditionally SetFocus the first tab in OnCurrent because that could cause the tab focus to switch as users navigate from one record to another using the record selector buttons. There could be cases where the users might find that annoying.
Instead, you might want to use the LostFocus event of the final field to manipulate a flag that would allow OnCurrent to SetFocus the first tab when the user moves to a new record by "falling off the end" of the previous record, but leave the tab focus alone if the user is just stepping through the records.
I have a form in MS Access 2007. To change from one inputfield to another the user can use tab or enter. The problem is when the user is in the last field and hit tab or enter she will jump to the next post. But I want to change this so the user jumps to the first filed in the same post or stays in the last field of the same post.
Maybe there is a very simple way to do this or do I have to write some vba?
I think the easiest way is to set the Cycle property to Current Record (Other tab on form properties), the default is All Records.