Posts Topics Forums Images
Search videos from message boards Videos Search messages from microblogs Microblogs Search messages from imdb.com Imdb Search messages from yuku.com Yuku Search messages from lefora.com (free forums) Lefora
My account: Login | Sign Up
Loading... 

Thread: setting form's recordset property in microsoft.public.access.formscoding

Started 3 weeks, 3 days ago by DoDev
I am having problems with setting form's recordset property. My subform's form_load event sub includes the following code: Private WithEvents rstA As ADODB.Recordset Dim SQLStmt As String Set rstA = New ADODB.Recordset SQLStmt = "SELECT * FROM tblA" rstA.Open SQLStmt, CurrentProject.Connection, _...
Site: Discussions in microsoft.public.access.formscoding  Discussions in microsoft.public.access.formscoding - site profile
Forum: microsoft.public.access.formscoding  microsoft.public.access.formscoding - forum profile
Total authors: 2 authors
Total thread posts: 2 posts
Thread activity: no new posts during last week
Domain info for: microsoft.com

Other posts in this thread:

Beetle replied 3 weeks, 3 days ago
A form has a RecordSource property, not a RecordSet property. The RecordSource property is a string, so you just use your SQL statement directly, rather than creating a record set and trying to use that, which would result in a Type Mismatch error. Dim SQLstmt As String SQLstmt = "Select * From TableA" Me.RecordSource =...

 

Top contributing authors

Name
Posts
Beetle
1
user's latest post:
setting form's recordset...
Published (2009-11-07 08:15:00)
  A form has a RecordSource property, not a RecordSet property. The RecordSource property is a string, so you just use your SQL statement directly, rather than creating a record set and trying to use that, which would result in a Type Mismatch error. Dim SQLstmt As String SQLstmt = "Select * From TableA" Me.RecordSource = SQLstmt -- _________ Sean Bailey "DoDev" wrote: > I am having problems...
DoDev
1
user's latest post:
setting form's recordset...
Published (2009-11-06 20:15:00)
  I am having problems with setting form's recordset property. My subform's form_load event sub includes the following code: Private WithEvents rstA As ADODB.Recordset Dim SQLStmt As String Set rstA = New ADODB.Recordset SQLStmt = "SELECT * FROM tblA" rstA.Open SQLStmt, CurrentProject.Connection, _ adOpenDynamic, adLockOptimistic Set Me.Recordset = rstA The last causes the following VB error: "the...

Related threads on "Discussions in microsoft.public.access.formscoding":

Related threads on other sites:

Thread profile page for "setting form's recordset property in microsoft.public.access.formscoding" on http://www.microsoft.com/communities/newsgroups.... This report page is a snippet summary view from a single thread "setting form's recordset property in microsoft.public.access.formscoding", located on the Message Board at http://www.microsoft.com/communities/newsgroups.... This thread profile page shows the thread statistics for: Total Authors, Total Thread Posts, and Thread Activity