Hi
Use the On Click event of your Command Button.
DoCmd.OpenForm "YourNewFormNameHere",,,"[IDNo] = " & Me.txtYourRecordIDFieldHere
IDNo is the unique record number (Primary Key) of the record you want to open, and Me.txtYourRecordIDFieldHere is the field on your form that contains that...
Hi
Does anyone know of a grid control (ActiveX) that can be used on a form that will enable drag and drop between cells and update the underlying data?
Basically it is to implement in a small guest house booking system (developed in A2002). The x-axis of the grid will be dates (which will need...
Hi
You could do it by opening a recordset........
Dim db As DAO.DataBase
Dim rs As DAO.RecordSet
Set db = CurrentDB()
Set rs = db.OpenRecordSet("YourTableName")
rs.AddNew
rs("FirstName") = Me.FName
rs("LastName") = Me.LName
etc..........
rs.UpDate
Set db = Nothing
Set rs = Nothing
HTH
Hi
Has anyone any experience of or used grid32.ocx (which I believe is for DAO recordsets) or msdatgrd.ocx (which is for ADO recordsets)? I can find info on using the controls via VB or C++ but not for implementing/using them in Access with VBA, or even registering either of them in Access.
I...
Hi Bill
Oooops, my apologies. I didn't notice a different poster, but many thanks for your solution to my latest headache - and also for your post Jim. Without help from people such as yourselves there would be a lot of non functioning db's!!
Thanks again
Alan
Hi Jim
Thanks for the reply. Still getting the type mismatch error even dropping the single quotes (MyInt is an integer)
If DCount("*", "tblMemos", "[NoteDate] < Date() - " & Myint & "" _
And IsNull("[ActionNotes]")) > 0 Then
Any other ideas...
Hi
Could someone please have a look at the following for me
If DCount("*", "tblMemos", "[NoteDate] < Date() - '" & Myint & "'" AND IsNull "[(ActionNotes]") = 0 Then etc
Basically I just want to check if [NoteDate] is less than two days...
Hi All
I've been trying to use the code supplied by Rolliee (in my case it doesn't matter whether it's the earliest or latest record thats retained) but up till now haven't managed to get it to work (type mismatch errors etc particularly the line okay = okay & (rs.fields(i) = ar(i))) although...
Hi
I've just looked at a db built by a family friend, and discovered many duplicate entries in a table (amongst other things lol). I've created a Find Duplicate query and then a delete query based on the Find Duplicate query, but that will obviously delete ALL occurences of the duplicate data...
Hi Hasu
Thanks for the reply. Will work on it tomorrow, my eyes are rapidly cosing right now and I need sleep!!
Thanks for your time and help
Cheers
Alan
Hi
Thanks for the reply. Your code stops the MS error message fine, but on clicking 'Yes' on the message box the form now closes instead of going back to the open form to input the missing data. Any thoughts?
Thanks for your time
Alan
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.