PC Review


Reply
Thread Tools Rate Thread

Code for Find Record Command on subforms....possible?

 
 
Mary
Guest
Posts: n/a
 
      20th Sep 2003
I have a form that has two subforms
I want to seacrh on what is on the suforms by using the
find record command. However, I can only search on the
main form fields..can anyone tell me why and how I can
fix this? Thank you in advance for your time and help.
Mary

 
Reply With Quote
 
 
 
 
Ken Snell
Guest
Posts: n/a
 
      20th Sep 2003
You could use the subform's RecordsetClone and its FindFirst or FindNext
methods.

From the main form:

Me.SubformName.Form.RecordsetClone.FindFirst "[FieldInSubform] = " &
SomeValue
Me.SubformName.Form.Recordset.Bookmark =
Me.SubformName.Form.RecordsetClone.Bookmark

where SubformName is the name of the subform control on the main form that
is actually holding the subform object.

--
Ken Snell
<MS ACCESS MVP>

"Mary" <(E-Mail Removed)> wrote in message
news:0f3101c37f7b$be6d3980$(E-Mail Removed)...
> I have a form that has two subforms
> I want to seacrh on what is on the suforms by using the
> find record command. However, I can only search on the
> main form fields..can anyone tell me why and how I can
> fix this? Thank you in advance for your time and help.
> Mary
>



 
Reply With Quote
 
mary
Guest
Posts: n/a
 
      21st Sep 2003
how does this work fro two subforms? or it doesn't?


>-----Original Message-----
>You could use the subform's RecordsetClone and its

FindFirst or FindNext
>methods.
>
>From the main form:
>
>Me.SubformName.Form.RecordsetClone.FindFirst "[FieldInSub

form] = " &
>SomeValue
>Me.SubformName.Form.Recordset.Bookmark =
>Me.SubformName.Form.RecordsetClone.Bookmark
>
>where SubformName is the name of the subform control on

the main form that
>is actually holding the subform object.
>
>--
> Ken Snell
><MS ACCESS MVP>
>
>"Mary" <(E-Mail Removed)> wrote in message
>news:0f3101c37f7b$be6d3980$(E-Mail Removed)...
>> I have a form that has two subforms
>> I want to seacrh on what is on the suforms by using the
>> find record command. However, I can only search on the
>> main form fields..can anyone tell me why and how I can
>> fix this? Thank you in advance for your time and help.
>> Mary
>>

>
>
>.
>

 
Reply With Quote
 
Ken Snell
Guest
Posts: n/a
 
      22nd Sep 2003
I'm not understanding you.... two subforms? You mean a subform within a
subform?

--
Ken Snell
<MS ACCESS MVP>

"mary" <(E-Mail Removed)> wrote in message
news:9b0e01c3803f$619a4120$(E-Mail Removed)...
> how does this work fro two subforms? or it doesn't?
>
>
> >-----Original Message-----
> >You could use the subform's RecordsetClone and its

> FindFirst or FindNext
> >methods.
> >
> >From the main form:
> >
> >Me.SubformName.Form.RecordsetClone.FindFirst "[FieldInSub

> form] = " &
> >SomeValue
> >Me.SubformName.Form.Recordset.Bookmark =
> >Me.SubformName.Form.RecordsetClone.Bookmark
> >
> >where SubformName is the name of the subform control on

> the main form that
> >is actually holding the subform object.
> >
> >--
> > Ken Snell
> ><MS ACCESS MVP>
> >
> >"Mary" <(E-Mail Removed)> wrote in message
> >news:0f3101c37f7b$be6d3980$(E-Mail Removed)...
> >> I have a form that has two subforms
> >> I want to seacrh on what is on the suforms by using the
> >> find record command. However, I can only search on the
> >> main form fields..can anyone tell me why and how I can
> >> fix this? Thank you in advance for your time and help.
> >> Mary
> >>

> >
> >
> >.
> >



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
RE: Command Button to find record WorkRelated Microsoft Access Macros 0 22nd Oct 2009 11:39 AM
Find record command =?Utf-8?B?TWFyYw==?= Microsoft Access Form Coding 3 31st Aug 2006 06:04 PM
Find Record Command Box =?Utf-8?B?S2FyZW5Mb3Vpc2U=?= Microsoft Access Database Table Design 3 10th Apr 2005 04:45 PM
Find Record Command Button JudyA Microsoft Access Form Coding 0 19th May 2004 07:18 PM
Using the find record command button John Baker Microsoft Access Forms 2 22nd Oct 2003 08:20 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:02 PM.