A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Open Form Action Button



 
 
Thread Tools Display Modes
  #1  
Old December 4th, 2005, 02:44 AM posted to microsoft.public.access
external usenet poster
 
Posts: n/a
Default Open Form Action Button


I have a form and a subform setup in access as two separate forms. On
the main form I do a search for a particular project that I want to add
comments to by using the subform. Once I find the project, I have a
button on the form to open the subform to add history to it, but when
the subform opens, the project that is shown does not match the project
I searched for in the main record .

How do I get the subform to open and match the project on the main form
automatically?

Thanks!


--
mafhobb
------------------------------------------------------------------------
mafhobb's Profile: http://www.hightechtalks.com/m428
View this thread: http://www.hightechtalks.com/t2300861

  #2  
Old December 7th, 2005, 01:35 AM posted to microsoft.public.access
external usenet poster
 
Posts: n/a
Default Open Form Action Button

On Sun, 4 Dec 2005 03:44:12 +0100, mafhobb
wrote:


I have a form and a subform setup in access as two separate forms. On
the main form I do a search for a particular project that I want to add
comments to by using the subform. Once I find the project, I have a
button on the form to open the subform to add history to it, but when
the subform opens, the project that is shown does not match the project
I searched for in the main record .

How do I get the subform to open and match the project on the main form
automatically?

Thanks!


Well, this isn't a subform. A Subform is a form that's in a Subform
control on a main form. What you're talking about is a popup form,
which is quite different!

You'll need to either drag the second form onto the first (perhaps
onto a Tab Control so you don't need to use too much screen space) and
make it a subform; or modify the VBA in the click event of the button
to pass the project ID:

DoCmd.OpenForm strDocument, WhereCondition := "ProjectID = " _
& Me!txtProjectID

or code to that effect.

John W. Vinson[MVP]
 




Thread Tools
Display Modes

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

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Visio Shortcuts [email protected] Visio 1 December 28th, 2006 11:28 PM
open form button vassilis Using Forms 6 December 3rd, 2005 05:22 PM
Move feild entries from form to form using global variables JackCGW General Discussion 11 November 14th, 2005 05:22 AM
Design help, please SillySally Using Forms 27 March 6th, 2005 04:11 AM
Cursor Positioning Colin Hammond General Discussion 3 November 2nd, 2004 08:42 PM


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


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.