Solved

label control not appearing

Posted on 1999-01-03
4
146 Views
Last Modified: 2010-05-18
I have a label control on a form with a grid1 control. when someone requests data to fill the grid control I set the label.visible=true, because it says "Please wait" but it dosn't work. The label control is initially set to false then when a person clicks on fillgrid the first command is to make it visible, but it stays invisible. If I F8 and step thru the program, when that command is reached it works perfectly, I have tried placing the label in different places on the form, but to no avail. I also have a check to inform the user that no data is available and if that event is triggered then before the msgbox pops up the label will become visible. This has me stumped, there is no reason why it shouldn't work. I have used this in other programs and it has worked fine the only difference is the grid control.
I am using VB4-16bit.
Any thoughts?
0
Comment
Question by:dtucker
[X]
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
4 Comments
 
LVL 3

Expert Comment

by:a111a111a111
ID: 1453671
one thought without looking at your code:

place exit sub just after you call the lable to be visible.

like this:

lable1.visible = true
exit sub


now you should see the lable visible and continue from there.

you can also email me your code or post it here.

shayplace@hotmail.com
0
 
LVL 2

Expert Comment

by:trillo
ID: 1453672
You're probably executing a lot of code (or time consuming code), and you don't give a chance to the label to paint itself... try something like:

label1.Visible = True
label1.Refresh
. next code statements...

Trillo
0
 

Expert Comment

by:Ajoy
ID: 1453673
dtucker,
as far as my exp with grid, it should cause u no problems.
try what Mr.shayplace has  written and if that works then check ur code for filling the grid.
regards,
ajoy
0
 
LVL 1

Accepted Solution

by:
jeffcameron earned 30 total points
ID: 1453674
use the doevents command, it will allow windows to repaint.

label1.Visible = True
doevents

0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
vb6 connector to SQL Server 2 42
Excel Automation VBA 19 116
Excel 2007 Random Generate List Based on Defined Source Cells 3 30
2 Global Vars, 1 List Box 4 33
Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

734 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