NotEnoughTime
asked on
Subform visible or hidden
Is there a way to have a subform be hidden on the form, and create a button to show the subform when needed,
I have tried to make a subform a popup, but the parent child link just isn't there when you want to add a record to the subform. It will show existing records, but won't let you add a record. (can't get the autonumber ID on the main form to fill in on the subform)
I would prefer not to use a second tab control if I can help it. the subform collects phone call information that needs to stay linked to the main form, but takes up too much space when it isn't needed.
Any suggestions would really be appreciated
MS access 2003 - windows XP Pro
Thank you
-C
I have tried to make a subform a popup, but the parent child link just isn't there when you want to add a record to the subform. It will show existing records, but won't let you add a record. (can't get the autonumber ID on the main form to fill in on the subform)
I would prefer not to use a second tab control if I can help it. the subform collects phone call information that needs to stay linked to the main form, but takes up too much space when it isn't needed.
Any suggestions would really be appreciated
MS access 2003 - windows XP Pro
Thank you
-C
Private Sub Command1_Click()
Me.YourSubFormControlName.
End Sub
mx
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
thank you everyone,
I am going to try DatabaseMX's code first, it seems the easiest
I will let you know
Thank you
I am going to try DatabaseMX's code first, it seems the easiest
I will let you know
Thank you
ASKER
mx
thanks so much, code worked great! I can now fit two suborms in the space for one by overlaying them ontop one another
Thank you
thanks so much, code worked great! I can now fit two suborms in the space for one by overlaying them ontop one another
Thank you
You are certainly welcome.
btw ... you can also add some code in there to toggle the Caption on the command button, ie Show/Hide or whatever makes sense.
mx
btw ... you can also add some code in there to toggle the Caption on the command button, ie Show/Hide or whatever makes sense.
mx
ASKER
I think I may have closed this question out a bit soon, If I need to repost I can, please let me know,
when the main form opens the subforms are showing
I would like them to be hidden when form opens, click button to show them then click again to close them If I make subform not visisble on form properties, i cannot get them to close when I clik on the button again
is this possible?
when the main form opens the subforms are showing
I would like them to be hidden when form opens, click button to show them then click again to close them If I make subform not visisble on form properties, i cannot get them to close when I clik on the button again
is this possible?
ASKER
disregard last post
it works, my access got hung up for a moment I restarted and it is fine
thanks so much
it works, my access got hung up for a moment I restarted and it is fine
thanks so much
http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com:80/support/kb/articles/Q210/6/00.asp&NoWebContent=1