My form gets its data from a single table. Each field on the form is linked to a field in this table.
Yesterday, running 'Docmd.Save' by clicking on a button saved the displayed data. Today, all of the fields are being saved, bar one.
I've checked that this field is still bound to the same table field and it is.
Could I have I inadvertently set some value that prevents this field being saved?
I have generated a report in acviewreport, after viewing the details I want to save the report as a pdf file with the client name, invoice number and date. In the report design view I added a cmd button and successfully coded it. However, it saves the report WITH the cmd button showing. I don't want this button saved. Is it possible to remove the button from the report AFTER I have clicked it?
I have a back end database that a number of people are working with using an Excel add-in that imports and edits records saved in the backend. Occasionally, when a user will update a record at first it saves to the backend but then an hour or two later, the changes made disappear. We have validated that after the user saves the changes, those changes are present in the backend of the database, but for some reason those changes disappear after a period of time.
I've been working on a database for work for the last few weeks and this forum has been a Godsend many times over, but now I have a problem that I can't find any reference to.
Using Access 2003, I have a form that uses 3 cascading combo boxes in the header to find a unique record, and a command button that brings up the rest of the record into unbound fields in the body of the form.
It works fine for finding records, but whenever I enter/change data on it, the record doesn't save. The navigation buttons at the bottom don't work - the Next/Previous record buttons are disabled, and the First/Last Record buttons do nothing.
Navigation buttons are enabled/activated in the properties.
I tried getting around this by creating a Save Record command button - first using the wizard, then using VBA code DoCmd.RunCommand acSaveRecord as advised by [missinglinq;696351], but this still doesn't save the changes.
I have a main form and subform. The main form is bound to a table of invoices and the subform to a table of invoice items. I'm picking up the invoice number from the form to save it to the invoice items table, so I need to save the record for the invoice before saving the invoice items from the subform.
I keep getting caught up in the same point over and over again. I need to save a calculated field's calculation to a table field. The problem is how do I do this? I already know about the rules but I need to do this and store that specific information. Can someone post a sample code? The problem is the code and codes I been using dont' seem to work any more. I was putting
fieldname = textbox2.txt in the form before update box. The problem with that is it would give me an error if the data source the calculation pulls from is not in the table/form.
When a form needs a calculated field. Say something simple, like
TotalCost = Quan*Cost
Is it better to create a query? Use a table and create the calculated field in the query builder? Or use a table and create a new unbound field on the form with the formula in it?
I never really know which one to do.
Lately I’ve been using saved queries for almost everything and now I have several dozen in this data base and its only half way done. Soon I’ll have to create a data base just to keep track of the queries in this one.
I have a small Database that produces invoices, Each invoice could have 5 items on it which are compeleted at different Dates. (cutting hair in an OAP Home) Invoice to be produced at the end of each month which shows what happened each week. This will be generated for each person in the home. I can display all the information in a form when inputing the invoice information. I want a button to copy the invoice number the client name and the total of the invoice to a new table. The total of the invoice is calculated control on the form.
How do I do this??? can anyone help
I need a total in a table to substract payments from.
I have a form with 4 combo boxes. Box 1 is linked to a unique indexed field of my main table and does not allow duplicates.
Is there a way I can enter selections in the other 3 boxes and save only those 3? (these do not add data, but edit an existing row in the main table)
Experimenting, I found that if I didn't make a selection in Box 1, I could still make selections in the other 3, close (save) the form, and it would make those 3 edits in the table row belonging to the value that was in Box 1.
This is kind of what I want, except that there are many selections in Box 1, and if I select one of them and close (save) the form, I get an error message that a duplicate entry will be made?
Would a possible solution be to have Box 1 on a main form and the other 3 on a subform? If so, how do I set this up? Or is there another way to relate the other 3 boxes to Box 1, and only save the 3.
I have a Combo Box that contains two fields, the key field (StudentId) and another field (StudentName). As recommended by the Combo Box wizard, I'm hiding the key field so only the StudentName displays in the box. The wizard also allows me to save only one of those fields in my table so I chose the key field (StudentId). Problem is, I need to store both the fields in my table. How do I store the two fields from the Combo Box in my table? I'm new to Access so I don't really know VBA that well.
I have a table with lots of different fields and field types. The two memo fields will not save. I have tried Runcommand and if me.dirty. Neither seems to work.All fields are from one table and I have tried deleting the fields and repopulating them onto the form to reset defaults. The only way the two fields save is if I hit Ctrl-S.
None of the 100+ fields on this one form (yes, it is large, weird part is it fits Normalization upthrough BNSF) have the same problem. They all save fine with or without the extra code. I am using Windows 7 and Access 2010.
I have a query, its been made from 4 table, one is Employee(all employees in my company), and other 3 are from tables Light Vehicles, Heavy Vehicles and MHE. When I run query its shom me all employees. If I put in query Is Not Null or <> in Light Vehicles for expample, its turn me back all records form Light Vehicle, but not all other records. If I dont put Is Not Null or <>"", its show me all employees. What I want is just to show me employees which have at least 1 record for Light, Heavy or Forklift, but not employees which doesnt have anything for Light, Heavy or MHE.
I have a form with a field that has formula for calculation. However, I am unable to link the field to the table since the control source is my formula.How can I that field to a table?
One of my tables has a couple of OLE Object fields. This has embedded Word, Excel, and PDFs. I'd like to know if there is a way to export these to a folder. Ideally, I'd like to save them with the record id and then a dash and then the file.
The fields are Attachment1, Attachment2, and Attachment3
When I view the table for these fields, if it's a word doc all I see is "Microsoft Word Document".
What is the correct way to save the values in a listbox column to the fields of a table? I can use rec("field1") = Me.list16.ItemData(Varitem)and that records the bound column to field 1 but how can I save the unbound columns to other fields in the table?
I want to only save changes made to the DB row when the user clicks the Save button I created. I have some text boxes which currently are bound to different columns in the given row (ex: name, address).
Right now, changes are updated automatically when the form is closed or when focus moves to a different tab page.
Is there any simple way to do this? Currently all form input objects are bound to their respective columns (ex: name, address). Should they be bound, or should I just perform a query when the form opens to find the specified item then load the different fields into the proper text boxes.
Also, when I TAB through all my input boxes and the TAB focuses on my Tab Conrol Object the text boxes are automatically updated with the next item n the DB (next row). How can I prevent this?
I want to create a Macro saves the report in a specific location, and uses two fields within the report to generate the name of the file. For example, "[Sales Rep Name] + [PayPeriod].pdf" and it should be saved in a predetermined folder.
In my UpdateForm I have 3 fields. PartNumber, Description and SerialNumber. I use 2 tables for these. My MainTable and PartsList Table.
In my PartsList table I have the list of PartNumber in Column (0) and Description in column (1).
In my MainTable I have 4 fields: TransactionID (autoNumber), PartNumber(text), Description(text) and SerialNumber (text).
Now, In my UpdateForm I want the user to just select the PartNumber with a combo box (that also show the "Description" (I created this using the combo box wizard)). But I want to auto populate the field in my "Description" text box every time the user will enter new record and will also update my MainTable with all the values they entered in my UpdateForm.
I tried this codes in the after update of PartNumber combo box (properties):
So I have this relatively simple problem: I need to create a button that once clicked will open the Save As dialog box and allow the user to save a copy of the current database where he wishes. The filename should contain todays date in DDMM format along with some pre-set text e.g. DDMM PresetText.
I have a few selected reports on an Access 2007 database that users can run. Is there a way for users to view the report, save as a PDF and automatically save a copy to a shared drive by modules/vba coding as an On Click event procedure?
I need code for save dialog file ,and select the file from textbox and save it to the selected location.i have only this code and i dont know what else i can do with this because it just opens the save file dialog !
thought I was ok at access, obvously not. Think 'briefcase' has messed with my db a bit so started using a backup with ext .BAK. Want to save whole db as another name with ordinary extension. Will only let me SAVEAS on bits of db?
Sorry, I know this is a bit simple but that's about right for me.
Hi all, when the users are saving the form, i want to make sure they have filled in certain fields. On previous forms my code has worked, but for some reason on this form it won't, i usually put:
If tankID = "" Then MsgBox ("Please Enter the Tank ID") tankID.SetFocus End If
Can anyone explain why it may not be working, thank you