Solved

Creating Status/Progress window

Posted on 2008-10-05
8
190 Views
Last Modified: 2011-10-19
Hi,

My code consists out of different kind of functions. I would like to keep the user informed which function is running at that moment.
What I did it setup a text field and update this text field which every progress. Like
text1.text="function 1 running"
text1.text="function 2 running"
etc

However this text window is not updated instantly. It has a huge delay. Does somebody know a solution?

Regards,
Dennis
0
Comment
Question by:Schuttend
  • 4
  • 3
8 Comments
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 22644815
after having set the .text property, call "DoEvents" to let VB repaint the screen.
0
 

Author Comment

by:Schuttend
ID: 22644841
But how I call this from within vb6?

Call Doevents

does not work

Regards,
Dennis
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 22644861
text1.text="function 1 running"
DoEvents
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 

Author Comment

by:Schuttend
ID: 22644899
I last question on this subject..

How can I update the textfile without losing previous information?

first message:
function 1 running

second one:
function1 running
function 1 finished

Text1.text=Text1.text & "new message"
does work a bit but the new message needs to be placed on the next line..

Regards,
Dennis
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 22645001
insert CR/LF character:

Text1.text=Text1.text & vbcrlf & "new message"
0
 

Author Comment

by:Schuttend
ID: 22645027
Hi,

This does not work. Please attached pic...

Regards,
Dennis
status.jpg
0
 
LVL 85

Accepted Solution

by:
Mike Tomlinson earned 50 total points
ID: 22645088
I haven't code in VB6 in awhile...but I'm pretty sure you need to set the MultiLine() Property of your TextBox to True.

0
 

Author Closing Comment

by:Schuttend
ID: 31503179
Hi..Sometimes the solution is that simple. Thanks!

Regards,
Dennis
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

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

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…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

770 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