473,416 Members | 1,544 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,416 software developers and data experts.

How to pop up "Busy Message" while running a process in ms access

20
Please help on how to show a busy message like "Please wait" or a "analytical animated watch" in ms access when a process in running.
Oct 7 '08 #1
14 22994
youmike
69
You need to identify the event which starts the process - clicking a control on a form, or whatever. In the VBA code for that event you simply add:

Expand|Select|Wrap|Line Numbers
  1. msgbox("BUSY RUNNING PROCESS")
.

This will cause a small window to appear, which the user can close by clicking on the OK button. You can make the msgbox function more complex. Try searching the VBA Help file for details.
Oct 8 '08 #2
yuvang
20
We can pop up the msg through msgbox option. but it will pop up with "OK" button and it will go off once the ok button clicked. then only the next line of code will be executed.


My expectation is to pop up that msg without "OK" button option and that msg should be there until the current running process completes, then automatically the msg should go off.

It is nothing but when a query or long process is running in system at the time our cursor symbol will change to "busy" mode. Thats i want as msg in our ms access, nothing else than that.
Oct 17 '08 #3
GazMathias
228 Expert 128KB
Please help on how to show a busy message like "Please wait" or a "analytical animated watch" in ms access when a process in running.
Normal way is:

Expand|Select|Wrap|Line Numbers
  1. Dim statusmsg as Variant
  2.  
  3.     statusmsg = SysCmd(acSysCmdRemoveMeter)
  4.     statusmsg = SysCmd(acSysCmdSetStatus, "Posting invoices to ledgers, please wait.")
This will appear on the status bar at the bottom left of the screen.

Gaz.
Oct 17 '08 #4
yuvang
20
I have removed the status bar in "StartUp". So if that is like Message will look good........
Oct 17 '08 #5
DonRayner
489 Expert 256MB
Have whatever process you start set a global variable and open a custom form. Have it unset the variable when the process is done running.

Use the on timer event of the custom form to monitor the status of the global variable and to close the form when it's unset.
Oct 17 '08 #6
yuvang
20
Can you please provide an example...........
Oct 17 '08 #7
DonRayner
489 Expert 256MB
Can you please provide an example...........
Create a standard module and declare a public variable at the top

Expand|Select|Wrap|Line Numbers
  1. Public YourVar as string
  2.  
In your process code put this at the top

Expand|Select|Wrap|Line Numbers
  1. YourVar = "running"
  2. Docmd.openform "YourFormName"
  3.  
And this at the exit point

Expand|Select|Wrap|Line Numbers
  1. YourVar = ""
  2.  
In the forms on timer event put this

Expand|Select|Wrap|Line Numbers
  1. If YourVar = "running" Then
  2.     Exit Sub
  3. Else
  4.     Docmd.close
  5. End If
  6.  
Oct 17 '08 #8
yuvang
20
Hi i have done that but still that is not working to me....


Let me explain what i have done...

i kept the below line

Expand|Select|Wrap|Line Numbers
  1. Public YourVar As String
in a module


then the



Expand|Select|Wrap|Line Numbers
  1. YourVar = "Please Wait"
in a on (Opens a form)click process in the same at the last i kept


Expand|Select|Wrap|Line Numbers
  1. YourVar = ""

then i kept the below code in same form's timer

Expand|Select|Wrap|Line Numbers
  1.  If YourVar = "Please Wait" Then
  2.      Exit Sub
  3.  Else
  4.      DoCmd.Close
  5.  End If
  6.  
Oct 17 '08 #9
GazMathias
228 Expert 128KB
Expand|Select|Wrap|Line Numbers
  1.  If YourVar = "Please Wait" Then
  2.      Exit Sub
  3.  Else
  4.      DoCmd.Close
  5.  End If
  6.  
Hi,

Looks like you need to reset the timer:

Expand|Select|Wrap|Line Numbers
  1.  If YourVar = "Please Wait" Then
  2.      Me.TimerInterval = 1000
  3.      Exit Sub
  4.  Else
  5.      DoCmd.Close
  6.  End If
  7.  
Also make sure its switched on to begin with.

Find the Form's "Timer Interval" property and put 1000 in there. This equates to one second, if memory serves.

So the above will run every one second until the variable is off, at which point the timer is not reset and the form closes.

Gaz
Oct 17 '08 #10
yuvang
20
You have given some code. But i am not clear that where i need to use them. So that i am not able to get any output. could you please clarify that ?
Oct 20 '08 #11
DonRayner
489 Expert 256MB
You have given some code. But i am not clear that where i need to use them. So that i am not able to get any output. could you please clarify that ?
Create a standard module and name it anything you want. Using VBA editor declare your public variable (whatever name you want) at the top of the module.

Using VBA editor edit the process you want the popup for and set your variable to = "Please Wait" and DoCmd.openform "Your Message Form" at the start of the process module. At the end of the process module set your variable back to nothing "".

In your message form properties change the timer value to 1000, in the on timer event add the code that was provided.

I'm sorry if I'm not explaining this clear enough for you but I've never been accused of being a good instructor. If it's still unclear what you need to do, maybe someone else can explain it better than I.
Oct 20 '08 #12
yuvang
20
Let me explain about my mdb.

It has a form “A” and there is a button to open another form “B”. While opening the form “B” it getting very late. So that what I want to display a message as “Please Wait”. The message should be there until the form “B” opens.


To this what I need to do. Please explain…..
Oct 20 '08 #13
GazMathias
228 Expert 128KB
Let me explain about my mdb.

It has a form “A” and there is a button to open another form “B”. While opening the form “B” it getting very late. So that what I want to display a message as “Please Wait”. The message should be there until the form “B” opens.


To this what I need to do. Please explain…..
Can I just ask why form "B" is taking so long to open? What does it do?

How often (if ever) do you Compact & Repair the .mdb?
Oct 20 '08 #14
yuvang
20
Hi



Can I just ask why form "B" is taking so long to open? What does it do?

Ans: The form "B" is having so many queries and 30 subforms, where i controlled them through visibilities.


How often (if ever) do you Compact & Repair the .mdb?

Ans: I am not Compact & Repair the mdb, once i post that to production server. are there any possibilities to that automatically........
Oct 21 '08 #15

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: placid | last post by:
Hi all, Just wondering if the cmd module in python uses "busy waiting" for "polling" user command input as this is inefficient. Cheers
3
by: Michelle Anderson | last post by:
Hi, I have this code so it will ask user if they want to save if they click on the "close" button. But some how it also pops up the message when I click on the save button. Is there a way to...
4
farooqbob
by: farooqbob | last post by:
When i sending a HTML mail I getting this Erro "could not access "CDO.Message" object" How can i fix this problem
4
by: ssq | last post by:
Hi, I wrote a RunSQL Macros to drop a table and used that on a button. How should i add an "Alert" to it i.e; i should get an "Alert Message" as soon as i click that button.
1
by: ashish | last post by:
Dim oCon Err.Clear Set oCon = Server.CreateObject("ADODB.Connection") If Err.Number = 0 Then '// '// Open an ADODB.Connection to the folder URL '// oCon.Provider = "ExOLEDB.DataSource"
6
by: arnuld | last post by:
I don't understand, every week I post "Welcome Message" as a new post and it gets posted as reply to my older "Welcome Message", automatically. What exactly is happening ? I have tried both PAN...
1
by: =?Utf-8?B?QUcgTW9yZW5v?= | last post by:
I had a virus. Ran Norton Antivirus. Now when I start my computer I get "FTP Port is used" error message and no internet access, however, computer is connected to wireless home network. Any...
7
by: saurabhsingh | last post by:
Can anyone plz suggest any Idea that How to implement "loading message" in a site with master pages. I am having Default page which is master page enabled and it contains many Gridviews with...
0
by: dieudonn | last post by:
Hi everyone! I want to add a toolbar (or a button ) to toolbars of the compose message window. I added a functional toolbar to the outlook main window. When i am supposed to add another toolbar...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.