Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Simple VBA question: Making a subform visible using a Case select in a Module

Posted on 2004-04-03
2
325 Views
Last Modified: 2006-11-17
Hello Everyody,

I got a form called frmMain. In that form there is a subform called frmDatum_Overzicht.
The subform is set to be invisible.

When a user enters data a count is made that is used in a Case Select structure in a Module.

I want tot make the subform frmDatum_Overzicht visible if the Case is 2 of 3.
In the Case = 2 block I got the following code.

        Forms!frmDatum_Overzicht.Requery
        Forms!frmDatum_Overzicht.Visible = True

When I run the above option I get the message "access can't find the form frmDatum_Overzicht".

I think Access can't find the form because it is a subform of frmMain. But I don't know how to program
that.

Any help is welcome!

ThanX
0
Comment
Question by:Geerd
2 Comments
 
LVL 77

Accepted Solution

by:
peter57r earned 125 total points
ID: 10747239
Hello Geerd,

> Forms!frmDatum_Overzicht.Requery
>         Forms!frmDatum_Overzicht.Visible = True


Forms!frmMain!frmDatum_Overzicht.Form.requery
Forms!frmMain!frmDatum_Overzicht.visible = true


Pete
0
 
LVL 1

Author Comment

by:Geerd
ID: 10747247
ThanX Pete
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
Many companies are looking to get out of the datacenter business and to services like Microsoft Azure to provide Infrastructure as a Service (IaaS) solutions for legacy client server workloads, rather than continuing to make capital investments in h…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question