Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms Programming / October 2005

Tip: Looking for answers? Try searching our database.

Visible Property

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Nuno Guerra - 26 Oct 2005 18:21 GMT
Hi!
I have an event with this code:
   picture1.Visible = True
   Lbl_Waiting.Visible = True
  ' Beginning the query to populate the List
   List1.RowSourceType = "Table/Query"
   List1.RowSource = "Q2"
   List1.ColumnWidths = "2000;900;3000"
   List1.Enabled = True
  ' End
   picture1.Visible = False
   Lbl_Waiting.Visible = False

This two objects never apears on run-time. It seams that the property
'Visible' only works after the query done.
What I want is a picture of a clock to be visible when the query is being
made.

Can someone help?
 
Ofer - 26 Oct 2005 18:25 GMT
Try and use the DoEvents after each comand
picture1.Visible = True
DoEvents
Lbl_Waiting.Visible = True
DoEvents
Signature

If I answered your question, please mark it as an answer. That way, it will
stay saved for a longer time, so other can benifit from it.

Good luck

> Hi!
> I have an event with this code:
[quoted text clipped - 16 lines]
> Can someone help?
>    
Nuno Guerra - 27 Oct 2005 09:38 GMT
It works!
Thanks a lot!

> Try and use the DoEvents after each comand
> picture1.Visible = True
[quoted text clipped - 22 lines]
> > Can someone help?
> >    
Dirk Goldgar - 26 Oct 2005 18:46 GMT
> Hi!
> I have an event with this code:
[quoted text clipped - 15 lines]
>
> Can someone help?

You may need something like this:

   Dim lngCount As Long

   picture1.Visible = True
   Lbl_Waiting.Visible = True
   DoEvents
   Me.Repaint
  ' Beginning the query to populate the List
   With List1
       .RowSourceType = "Table/Query"
       .RowSource = "Q2"
       .ColumnWidths = "2000;900;3000"
       .Enabled = True
       lngCount = .ListCount  ' force complete population
   End With
  ' End
   picture1.Visible = False
   Lbl_Waiting.Visible = False
   '** PROBABLY DON'T NEED THESE 2 LINES HERE:
   'DoEvents
   'Me.Repaint

Signature

Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)

Marshall Barton - 26 Oct 2005 18:54 GMT
>I have an event with this code:
>    picture1.Visible = True
[quoted text clipped - 12 lines]
>What I want is a picture of a clock to be visible when the query is being
>made.

The screen updating is done as a background activity
compared to code execution.

Try using:
    Me.Repaint
after making the two controls visible.

You may or may not need to do it again after making them
invisible.

It's also possible that you may need to add one or two
DoEvents after the Repaint.

Signature

Marsh
MVP [MS Access]

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.