Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / General 1 / May 2008

Tip: Looking for answers? Try searching our database.

Runtime error 424: Object required

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
gmazza - 12 May 2008 22:30 GMT
Hi there,
I am a novice at Access programming but I am flustered by this error and
don't understand what I am doing wrong, any help is appreciated.
Here is my code:
Sub SetFilter()

   Dim LSQL  As String
 
   LSQL = "select * from dbo_DDXLMO"
   LSQL = LSQL & " where St_Offshore = '" & cboSelected & "'"

   Form_frm_OffsetWells_sub.RecordSource = LSQL

End Sub

I am calling the SetFilter routine from my Form_Open Procedure and all I have
is a form and subform and in the form I have an unbound combo box that
selects St_Offshore from table dbo_DDXLMO.
I am just trying to populate the subform with results from my combo box and I
keep getting this error and I have tried a million things and nothing is
working.
Please help, thanks!
Salad - 12 May 2008 22:52 GMT
> Hi there,
> I am a novice at Access programming but I am flustered by this error and
[quoted text clipped - 18 lines]
> working.
> Please help, thanks!

You might want to try the following format
    Forms!MainFormName!SubFormName.Form.Recordsource = ...
or
    Me("SubFormName").Form.Recordsource = ...

Brass
http://www.youtube.com/watch?v=1qdvz0uPpNk
gmazza - 12 May 2008 23:05 GMT
>> Hi there,
>> I am a novice at Access programming but I am flustered by this error and
[quoted text clipped - 9 lines]
>Brass
>http://www.youtube.com/watch?v=1qdvz0uPpNk

I tried your suggestion and it now errors:
Access can't find the field (SubFormName) referred to in your expression.
Its not a field though, not sure what its talking about...
Thanks for the fast response.
Pachydermitis - 12 May 2008 23:27 GMT
> >> Hi there,
> >> I am a novice at Access programming but I am flustered by this error and
[quoted text clipped - 17 lines]
> --
> Message posted via AccessMonster.comhttp://www.accessmonster.com/Uwe/Forums.aspx/databases-ms-access/2008...

lol.  Form_frm_OffsetWells_sub.form.RecordSource = LSQL
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.