I want to open a form based on a record selected in a subform. Can you refer to one record in a subform that displays multiple records? I know you can refer to the subform itself, but I want to refer to a particular record on the subform.
![]() |
There are isolated problems with current patches, but they are well-known and documented on this site. |
SIGN IN | Not a member? | REGISTER | PLUS MEMBERSHIP |
-
Open form based on subform record (Access97 SR2)
Home » Forums » AskWoody support » Productivity software by function » MS Access and database help » Open form based on subform record (Access97 SR2)
- This topic has 4 replies, 3 voices, and was last updated 23 years, 9 months ago.
Viewing 0 reply threadsAuthorReplies-
WSMarkLiquorman
AskWoody LoungerSeptember 5, 2001 at 7:36 pm #540828>>I want to open a form based on a record selected in a subform. Can you refer to one record in a subform that displays multiple records? I know you can refer to the subform itself, but I want to refer to a particular record on the subform.<<
When you refer to a control on a continuous form, you are always get the value that is on the line with the focus. Perhaps you could explain exactly what you are trying to do? That is, do you want to click a button on the mainform, or is the button on the subform?
-
WSclaudie
AskWoody LoungerSeptember 5, 2001 at 8:19 pm #540833 -
WSclaudie
AskWoody Lounger -
WSFrancois
AskWoody LoungerSeptember 6, 2001 at 12:19 pm #540957Claudie,
In the on click event of the button use code like
Private Sub cmdButton_Click() On Error GoTo Err_cmdButton_Click Dim stDocName As String Dim stLinkCriteria As String stDocName = "Yourform" stLinkCriteria = "[yourfield] = 'yourcondition'" DoCmd.OpenForm stDocName, , , stLinkCriteria Exit_cmdButton_Click: Exit Sub Err_cmdButton_Click: MsgBox Err.Description Resume Exit_cmdButton_Click End Sub
-
-
Viewing 0 reply threads -

Plus Membership
Donations from Plus members keep this site going. You can identify the people who support AskWoody by the Plus badge on their avatars.
AskWoody Plus members not only get access to all of the contents of this site -- including Susan Bradley's frequently updated Patch Watch listing -- they also receive weekly AskWoody Plus Newsletters (formerly Windows Secrets Newsletter) and AskWoody Plus Alerts, emails when there are important breaking developments.
Get Plus!
Welcome to our unique respite from the madness.
It's easy to post questions about Windows 11, Windows 10, Win8.1, Win7, Surface, Office, or browse through our Forums. Post anonymously or register for greater privileges. Keep it civil, please: Decorous Lounge rules strictly enforced. Questions? Contact Customer Support.
Search Newsletters
Search Forums
View the Forum
Search for Topics
Recent Topics
-
Windows AI Local Only no NPU required!
by
RetiredGeek
1 hour, 51 minutes ago -
Stop the OneDrive defaults
by
CWBillow
4 hours, 54 minutes ago -
Windows 11 Insider Preview build 27868 released to Canary
by
joep517
7 hours, 19 minutes ago -
X Suspends Encrypted DMs
by
Alex5723
9 hours, 31 minutes ago -
WSJ : My Robot and Me AI generated movie
by
Alex5723
9 hours, 49 minutes ago -
Botnet hacks 9,000+ ASUS routers to add persistent SSH backdoor
by
Alex5723
10 hours, 26 minutes ago -
OpenAI model sabotages shutdown code
by
Cybertooth
11 hours, 3 minutes ago -
Backup and access old e-mails after company e-mail address is terminated
by
M W Leijendekker
6 hours, 21 minutes ago -
Enabling Secureboot
by
ITguy
6 hours, 13 minutes ago -
Windows hosting exposes additional bugs
by
Susan Bradley
18 hours, 58 minutes ago -
No more rounded corners??
by
CWBillow
14 hours, 46 minutes ago -
Android 15 and IPV6
by
Win7and10
4 hours, 31 minutes ago -
KB5058405 might fail to install with recovery error 0xc0000098 in ACPI.sys
by
Susan Bradley
1 day, 7 hours ago -
T-Mobile’s T-Life App has a “Screen Recording Tool” Turned on
by
Alex5723
1 day, 10 hours ago -
Windows 11 Insider Preview Build 26100.4202 (24H2) released to Release Preview
by
joep517
1 day, 4 hours ago -
Windows Update orchestration platform to update all software
by
Alex5723
1 day, 17 hours ago -
May preview updates
by
Susan Bradley
1 day, 4 hours ago -
Microsoft releases KB5061977 Windows 11 24H2, Server 2025 emergency out of band
by
Alex5723
20 hours, 18 minutes ago -
Just got this pop-up page while browsing
by
Alex5723
1 day, 9 hours ago -
KB5058379 / KB 5061768 Failures
by
crown
1 day, 6 hours ago -
Windows 10 23H2 Good to Update to ?
by
jkitc
8 hours, 46 minutes ago -
At last – installation of 24H2
by
Botswana12
2 days, 8 hours ago -
MS-DEFCON 4: As good as it gets
by
Susan Bradley
5 hours, 33 minutes ago -
RyTuneX optimize Windows 10/11 tool
by
Alex5723
2 days, 21 hours ago -
Can I just update from Win11 22H2 to 23H2?
by
Dave Easley
19 hours, 29 minutes ago -
Limited account permission error related to Windows Update
by
gtd12345
3 days, 10 hours ago -
Another test post
by
gtd12345
3 days, 10 hours ago -
Connect to someone else computer
by
wadeer
3 days, 5 hours ago -
Limit on User names?
by
CWBillow
3 days, 8 hours ago -
Choose the right apps for traveling
by
Peter Deegan
2 days, 22 hours ago
Recent blog posts
Key Links
Want to Advertise in the free newsletter? How about a gift subscription in honor of a birthday? Send an email to sb@askwoody.com to ask how.
Mastodon profile for DefConPatch
Mastodon profile for AskWoody
Home • About • FAQ • Posts & Privacy • Forums • My Account
Register • Free Newsletter • Plus Membership • Gift Certificates • MS-DEFCON Alerts
Copyright ©2004-2025 by AskWoody Tech LLC. All Rights Reserved.