I am using Access 2013. I have a form with 2 subforms, each time the form is opened, the first record on both subforms are selected. Is there a way to turn off the record selector so no records are selected when the form opens?
I have created some control buttons using the built in functions of Access2007 and then using the script supplied here modified the control.
So far the controls can add new record, save record, exit form, open next form and close existing form, open previous form and close existing form.
My next question is when the user reaches the end of the form fields how do I stop the form from automatically starting a new record?
For example, I use the TAB key to move from field to field and when I tab out of the last field the form goes straight to the next empty record.
I want this to be a deliberate action performed by clicking the Add New Record button and not an accident of a key press.
The other thing is, how do I get the form to open with blank/empty fields and not at the first populated record? Some of the data is updated frequently so the records need to be able to be edited but I need to prevent accidental editing of the existing records.
When moving from a subform back to the mainform and requerying one of the mainform controls, the record selector of the subform moves back to its first record. ...
GoToRecord (,,Next) '(in the subform-this is correct) SelectObject Object Type Form Object Name pv '(go back to the main form) In Database Window No GoToControl (SubTot)
Requery (SubTot)If I remove the Requery, the record selector remains where it is supposed to be. The SubTot data source does include the aggregate dsum value of the subform's underlying table. What is strange is that this has been running properly for many years until it was upgraded from .mdb to .accdb format. Is there an easy way to make the record selector stay put?
My problem is related to an Access database, where an auto complete Combo box is used to select a client record by entering the ID number or the clients name. EG: 14034 or Bloggs,Fred. This problem has me puzzled (not difficult to do).I have seen this in a functioning DB. I can see that maybe the ID (a long integer) would have to be stored or converted to a string on the fly.
I am currently using Access 2007 but 2010 and 2013 are available (prefer 2007 as MS keep moving things around ).I am currently selecting a client record using either an ID select Combo or a ClientName Combo and works very well. But, after seeing it done in one Combo box, it just seems so elegant.
Combo2 - Record selector that works, either shows a list of facilities or list of physicians. Macro SearchForRecord - Where Condition ="[fac_id] = " & Str(Nz([Screen].[ActiveControl].[Column](0),0))
Would like it to be
="[fac_id] = " & Str(Nz([Screen].[ActiveControl].[Column](0),0)) AND [referral_type] = Me!Combo2
In the zip-file attached below is my "problem" database. (to see the problem open frmLedenArtikels) On top of the form just select a name from the combo box, the subform then lists the items that person has bought on a certain date. So very easy form.
The problem is the following. When I try to add items to the subform, the record selector in the subform always automatically jumps back to the first record in the subform. this is very annoying and I have totally no clue why this is happening.
i wonder if anyone can help with this problem i cant seem to work out.
i have a bound form linked to an orders table, including some required fields. when i use the navigation buttons of the form to scroll thorugh the orders i can get to the end where the form expects you to make a new order. but i have a button to add a new order.
i want to stop the user being able to go past the last record in the orders table. or enable them to get back to the last order. currently if the user goes past the last record (making a new order) there is no way to get back to the last record. using the navigation back button causes errors as the required fields are blank and access tries to save the order, thinking i want to make a new one.
i hope this makes sense.
i have tried setting the Allow Additions setting of the Form to No. but this causes problems when there is no data in the orders table. opening the form produces a blank form, showing no fields or buttons at all.
i would be greatful for any advice, maybe i am doing something fundamentally wrong?:confused:
i wonder if anyone can help with this problem i cant seem to work out.
i have a bound form linked to an orders table, including some required fields. when i use the navigation buttons of the form to scroll thorugh the orders i can get to the end where the form expects you to make a new order. but i have a button to add a new order.
i want to stop the user being able to go past the last record in the orders table. or enable them to get back to the last order. currently if the user goes past the last record (making a new order) there is no way to get back to the last record. using the navigation back button causes errors as the required fields are blank and access tries to save the order, thinking i want to make a new one.
i hope this makes sense.
i have tried setting the Allow Additions setting of the Form to No. but this causes problems when there is no data in the orders table. opening the form produces a blank form, showing no fields or buttons at all.
i would be greatful for any advice, maybe i am doing something fundamentally wrong?:confused:
Does anyone know how to remove the "Record ID" from the record selector? I want to be able to traverse from one record to the next, however I do not want the field representing what record it is on showing up ( if that makes any sense).
I have a macro that opens up a form called SLA Complete Form - The macro then goes and examines two fields on the form to see if they contain data and if they do not then it displays a popup box with a message.
The form that gets opened up can have anywhere from one record to approximately a hundred records.
How can I get the macro to stop running when it hits the last record on the form without displaying an error message. I am currently using the next record feature in the macro.
Hi All, I have a form that when loads, runs some VBA on the "On Current" event. Some of that code, fills in text boxes, with concatenated (?) strings. So every time I use the record selector and get to the end of all the records, the "On Current" fires adds the concatenated string (even if it's empty), and that then becomes a new record! Is there some way i can prevent this, but still keep the "On Current" event, some type of logic I could run before the concatenations etc.
How do I remove a record selector from a subform? I went to the actual form for the subform and went into design view. I changed the record selector to NO and it is still there.
I have a table with fields ID, NAME, ITEM, QUANTITY and DATE_IN. I have a query "qry_Logged_In" based on the table. I then have a form based on the query.
I created a combo box as a "go to record" selector and used the following Row Source:
SELECT DISTINCTROW qry_Logged_In.ID, qry_Logged_In.NAME, qry_Logged_In.ITEM, qry_Logged_In.QUANTITY, qry_Logged_In.DATE_IN FROM qry_Logged_In ORDER BY [ID];
On the After Update proceudre I have the following code:
Sub Combo135_AfterUpdate() ' Find the record that matches the control. Me.RecordsetClone.FindFirst "[ID] = " & Me![Combo135] Me.Bookmark = Me.RecordsetClone.Bookmark End Sub
It works fine, but one thing I would like is that as I toggle through records using the record selector (forward/backward) buttons, I would like for the record number in my combo box to also change keeping in sync with the record number. Unfortunately, it currently stays to the number I last selected in the combo box.
Any suggestions on how to make the record number showing in my combo box to change with the record number?
I am building a student register for a school for disabled children. There is a screen listing all students, one showing detailed student data chosen by #=IIf(IsNull([ID]),"(New)","Open")# clicking on "Open", one listing all the guardians, choosing a guardian by #=IIf(IsNull([ID]),"(New)","Open")# clicking on "Open", to diaplay Guardian details.
From the student list, I select and view student details, including a pointer to their guardian details. After selecting the first student details, and then viewing their guardian data, any subsequent student details and guardian details updates the prior guardian data with the next guardian's data.
How can I prevent the successive guardian details from updating the prior guardian table when it is exited? I view the guardian details using ADO recordsets populating a form. When I exit, it updates the previous record.
How do you prevent access from adding a new record when u input data in the current record or tab to the next field? My database is set up to open with a form where the user picks his name and then a week ending date once that is complete u open a new form where the name and date auto populate along with other fields to fill out such as job charge, charge type , times charged for each day of the week. But I don't want access to create a new record everytime the person inputs or tabs..... .
I have a form that opens to a NEW record, all fine and grand. there are a few drop down choices, and modern users are using the scroll button to try to move up and down the list in the drop down boxes, but this action actually tries to move to the next record, causing an error as fields are blank etc (which is fine) but its confusing everyone.
the nav buttons are not shown on the form, so what can we do to stop the form trying to goto another new record?
the form is opened using a macro, where the action is OpenForm (view=form, data mode=Add and window mode=Normal) GoToRecord (record=new).....
Hi, In Access 2007, I don't seem to be able to scan through a few records by holding down the advance record arrow in tables liked I used to?! Am I missing something here, it worked in the same way in all other versions, the same as if you use the mouse wheel, it should run through each record in turn.
Is there a way to change this? I've been through all the settings I can think of...
Hi Can anyone confirm (or otherwise) that you can't set the record selector property to 'no' in a datasheet view form? (well, you can set it to 'no' but it seems to have no effect)
I have some code (see below) that checks if the start date text box is blank or greater than the end date, and if so, generates a message box and sets the focus back to the start date textbox. There are command buttons on the form that open queries based on the date fields. This all works fine.
However, if the user changes his mind and closes the form without filling in the date field, the message box "Please enter a start date" pops up repeatedly. How do I specify that a text box is required UNLESS the user is closing the form?
Code: Private Sub txt_startdate_LostFocus() If ((IsNull(txt_startdate) Or (txt_startdate) = " ")) Then MsgBox "Please enter a start date.", vbOKOnly
I have a form in which user will enter few values but I need users to enter the comment in relevant text box too only if they have any non zero value.
I have attached an example for reference....where red encircled portion is for values and blue is for relevant comments. If value is non zero then user should be enforced to enter the comment too......system should not allow user to move forward or backward until there is some comment.
I'm new to Access so apologies in advance if this occurs as simple-headed...
Given a group identifier (e.g. department) I want to display a list of members (e.g. employees) in that group. So I use a sub-form in datasheet view.
Now I want to associate an independant checkbox with each row so that I can identify partiuclar members for some action (e.g. assign to a project).
Thus, I need to set up the checkboxes on each rsub-form ow and then be able to probe them later and get their state and any other info on the row (e.g. key(s) for the individual members).
I'm writing a course registration Db. I have a have 3 tables at the moment tblContacts [ContactID], [FName], [SName], [Etc..] tblCourseRegistration[RegID] [ContactID][CourseID] and tblCourses[CourseID] [CourseName] [Etc...]
These are all linked on a tabbed form. I have found that the same Contact can sign up for the same course twice. I need to stop this happening. Is there an easy way to prevent this or do I have to write a query that runs before the save command to prevent this?