Hi
WinXPPro - SP3
Access 2007
.mbd file
Native Access Db on Local Machine
Sorry to post again so soon but I've an issue with ADO RS's and I'm completely out of ideas. I started to implement these some weeks ago and wish I'd not bothered!
I have main and 6 subforms. All are built as I've seen in various examples:
Each SubForm SELECTs from different tables.
My main form current event co-ordinates the main and subforms as here:-
All works perfectly.... until I add a new record into the main form RS. When I have finished doing so I "requery" it with :-
Set me.form.recordset = me.form.recordset (it's not DAO).
This works around all the subforms calling their unload events and then open events.... so they are all re-loaded as they were originally loaded above...
Now, however, the filtering of the subforms or indeed any mention of them e.g.
With My_SubForm.Form
.Recordset.Filter
causes Access to immediately crash?!? Any ideas anyone please?
WinXPPro - SP3
Access 2007
.mbd file
Native Access Db on Local Machine
Sorry to post again so soon but I've an issue with ADO RS's and I'm completely out of ideas. I started to implement these some weeks ago and wish I'd not bothered!
I have main and 6 subforms. All are built as I've seen in various examples:
Code:
Option Explicit
Private Frm_RstADO1 As ADODB.Recordset
Private Frm_CnnADO1 As ADODB.Connection
OPEN EVENT
----------
Set Frm_CnnADO = CurrentProject.AccessConnection
Set Frm_RstADO = New ADODB.Recordset
SQLLine = "SELECT TBL1.* FROM Addrs AS TBL1 "<--- may get JOINED later
With Frm_RstADO
Set .ActiveConnection = Frm_CnnADO
.Source = SQLLine
.LockType = adLockOptimistic
.CursorType = adOpenKeyset
.CursorLocation = adUseClient
.Open
End With
Set Me.Form.Recordset = Frm_RstADO
Set Frm_RstADO = Nothing
Set Frm_CnnADO = Nothing
My main form current event co-ordinates the main and subforms as here:-
Code:
With My_SubForm.Form
.Recordset.Filter = adFilterNone
.Recordset.Filter = "[Addrs_Unique_No]=" & Me!TBL1_Unique_No <--- main form key
Set .Recordset = .Recordset
End With
Set me.form.recordset = me.form.recordset (it's not DAO).
This works around all the subforms calling their unload events and then open events.... so they are all re-loaded as they were originally loaded above...
Now, however, the filtering of the subforms or indeed any mention of them e.g.
With My_SubForm.Form
.Recordset.Filter
causes Access to immediately crash?!? Any ideas anyone please?