Solved

Why frmStation pop out during processing

Posted on 2000-02-25
6
155 Views
Last Modified: 2010-05-02
Could someone please tell me why is the frmStation pop out during the execution whereas I didn't put frmStation.Show?

Private Sub Search()
:
:

criteria = "GaugeNo = '" & stno & "'"
frmStation.datLocation.Recordset.FindFirst criteria

If frmStation.datLocation.Recordset.NoMatch = True Then
    Msg = MsgBox("Could not find station based on gauge no: " & StationNo, vbExclamation, "Error")
    ILOCATION = UCase(InputBox("Please enter station name", "Station Name", , 3000, 2400))
Else
    ILOCATION = UCase(frmStation.datLocation.Recordset("StationName"))
End If

:
:
End Sub
0
Comment
Question by:suhani
6 Comments
 
LVL 10

Expert Comment

by:caraf_g
ID: 2557135
Perhaps because you're using data-bound controls and they're doing something to show their parent form?

0
 

Expert Comment

by:pinshah
ID: 2557154
if u start using controls on the forms the controls needs to be loaded which in turn loads the form and shows the form
0
 
LVL 10

Expert Comment

by:caraf_g
ID: 2557179
Who's "u"?

Yes... the controls need to be loaded, but that doesn't necessarily show the form.

Try this:

Private Sub Main()

Form1.Text1.Text = "hello world"

End Sub

Form is loaded, but not shown.
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 1

Accepted Solution

by:
PatrickVD earned 50 total points
ID: 2557673
Are you using MDIForm and child windows ???
If so, you might have forgotten to switch of the AutoShowChildren property of the MDIForm ?
0
 
LVL 10

Expert Comment

by:caraf_g
ID: 2557713
DOH! Never thought of that! Good point, Patrick.
0
 

Author Comment

by:suhani
ID: 2561990
Thanks!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

930 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now