Thanks Aric,
I have too many users to go throw this. Also I allow people to enter new User names in the user field. I'll have to update a file or the database to add the department.
I'm still not clear on how to link the user to his or her department.
Kevin
User Profile
Collapse
-
Auto Populate Form using Combo Box's
Hello,
I'm using access 2007 and have one table (Assets). In my table there is a User field (Assets.User) and Deptartment. field (Assets.Departm ent). On my form I have a combo box for User (cboUser) and a combo box for Department (cboDepartment) . Currently they are both individual drop downs with the User and Group names listed in the row source.
On the form, the data entry person will select a user. Once that User... -
Thanks puppydogbuddy,
For some reason, I do not receive the errors anymore. I've been testing it a lot today. I'll make the changes if I run into the error again. Thanks again for all of your help. You were so patient with me and gave me a bunch of solutions. Thanks for your time.
KevinLeave a comment:
-
Thanks for the code,
I still get the same error , The command or action 'DeleteRecord' isn't available.
I did use my old code with the open query and added your solution to not show the query and it seemed to work.
I do like the way your code works though. You can actually see the item being deleted from the form.
Is there any other reason I would be getting this Run-time error '2046'...Leave a comment:
-
I tried all of the solutions and the qry still pops up over the form. Here is my code for the delete. I'm using access 2007, not sure if that has anything to do with it.
Code:Private Sub cmdMultiDeleteRecord_Click() Dim DeletedQty As Integer If Me.Dirty Then Me.Dirty = False DoCmd.SetWarnings (WarningsOff) If Not IsNull(Me.NumberDeleted) Then DeletedQty
Leave a comment:
-
Hi,
I tried DoCmd.OpenQuery "qryAssetListBo x" and the query still shows up.
KevinLeave a comment:
-
Thanks for your help,
I got the DCmd.OpenQuery to work. The only problem I have is that when I open the query the data sheet view opens and then does the delete. I'm able to close the form after it's done but this looks bad to the user because the datasheet opens over the form. Is there anyway to keep the datasheet view in the background so the user can't see it.
Thanks again,
KevinLeave a comment:
-
I'm pretty new at this stuff, so I'm going to need more help. So right now my form has a list box that lists all of the records in my table. Once I select one record I delete the selected record and then the next record. This just continues until the number of records is deleted. My records are sorted by Item description so you can delete mutliple records of one item.
As for the query, would i just create a query that list the...Leave a comment:
-
The problem still exists but only when I'm deleting a large quantity like 200. Anything under 100 seems to work fine.
Any other ideas?
KevinLeave a comment:
-
-
Delete Command has error when deleting multiple records.
Hi All,
I got a multiple delete working here but for some reason I occassionally get this error. The way the delete works is there is a text box where the user enters the quantity to delete. If it is blank it will delete 1 item. It never fails when I delete just 1 item but if I delete more than one item it fails but only some times. Here is the error:
"Run-time error '2046':
The command or action... -
-
-
Hi Don,
I am pulling up a record, but each record is a quantity of 1 because most of my records have serial numbers. However we do have parts that do not have serial numbers. Each record represents 1 item in inventory. I have a text box on my form where the user can enter a qty to delete. So first the user selects the item (item without a serial number), then enters a qty in a text box, then hits the delete button on the form....Leave a comment:
-
Thanks for everybody's help,
but I'm using an inventory system. On the form there is a list of all the items in the database. I can not just delete all items without a serial number. The user selects a record from the list, and the form brings up the record and all of it's fields. I'd like the user to input a qty from a text box and the Delete button read that qty and then delete. Here is what I have so far.
Asset...Leave a comment:
-
Thanks for your help all,
I was wondering if my Delete can work like my Copy,
Private Sub cmdMultiCopy_Cl ick()
Dim Copies as Integer
If Me.Dirty Then Me.Dirty = False
If Not IsNull(Me.Numbe rCopies) then
Copies = Me.NumberCopies
Else
Copies = 1
End If
For I = 1 To Copies
DoCmd.RunComman d acCmdSelectReco rd
DoCmd.RunComman d...Leave a comment:
-
-
Hi,
Thanks for the fast response. I put the code in but I get a compile error at 'Dim db As Database' (Compile error: user-defined type not defined). I checked ?CurrentProject .Connection and it came back with Provider=Micros oft.ACE.OLEDB.1 2.0. I also tried DAO.Database and DAO.Recordset but I still get the same error.
Thanks,
KevinLeave a comment:
-
Delete Multiple Records On A Form
I have an existing inventory database that I'm trying to make changes to. The database only has 1 table with the following fields:
PartNumber
ItemDescription
Category
Location
Owner
SerialNumber.
Currently I'm using the delete button to delete a single item.
Code:Private Sub cmdDeleteRecord_Click() On Error GoTo Err_cmdDeleteRecord_Click 'DoCmd.DoMenuItem acFormBar,
-
More questions about this....
How will the delete command know what to delete when it has to delete multiple copies? The copy command selects the record and just creates a duplicate but the delete is much different because it will have to know which record to delete.
Thanks,
KevinLeave a comment:
No activity results to display
Show More
Leave a comment: