473,386 Members | 1,830 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,386 software developers and data experts.

Run a Queery on a schedule time

Can I set up an append query to run at preschedule time every day of the week?
Thanks
CharlesCount

Jul 6 '07 #1
2 2231
On Fri, 06 Jul 2007 02:45:59 GMT, "CharlesCount" <u35616@uwewrote:

I just answered a very similar question the other day.
Groups.google.com is a great resource.
The answer: Yes.
Use the Windows Scheduler to schedule this command line:
<path to>msaccess.exe <path to>your.mdb /x YourMacro
This macro would run your append query.

-Tom.

>Can I set up an append query to run at preschedule time every day of the week?
Thanks
CharlesCount
Jul 6 '07 #2
It can be done within access too.

Here is some sample code I used before; this code requires access to
be running to be executed.

Sub Form_Load()
Me.TimerInterval = 1 * 60 * 1000
'60000 = 1 Minutes
'The above to check your computer's clock every 1 minute
End Sub

Sub Form_Timer()
Dim MyTime As Variant

MyTime = Time

If MyTime >= TimeSerial([Forms]![Main]![HR], [Forms]![Main]![MN], 0)
Then

'In a form, place couple of boxes to indicate the time in hours (text
box HR)
'and in minutes (text box MN) - so you enter 20 in HR and 15 in MN for
this
'action to be triggered at 08:15 PM

Me.TimerInterval = 0

DoCmd.RunSQL "DELETE [OH Aus].* FROM [OH Aus];"
'The above deletes data using SQL statements
DoCmd.OpenQuery "On Hand Aus", acNormal, acEdit
'The above appends data running an MS Access action query

DoCmd.Quit
'This to quit the application if this is what you want to do after
the set time
End Sub

Jul 7 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: ensnare | last post by:
Currently, I have a database that stores a course schedule. For example: Course Title, Start Time (datetime), End Time (datetime), Mon (T/F), Tues (T/F), Wed (T/F) Thurs (T/F), Fri (T/F) I...
2
by: mustafa | last post by:
Dear Sir, I want to send the bulk MAil to the user at a schedule task.I am using ASP and Sql server 2000. i want to schedule the Date & time like in SQL Server 2000 there is feature to...
1
by: bigfella | last post by:
Hi Everyone, I am using the following code (many thanks for the code folks BTW) to generate 3 schedules in three tables one is a schedule with 7 day intervals and two are daily schedules. The...
1
by: greg7224 | last post by:
I am currently working on a C# project that uses the Janus schedule controls, and am having trouble getting it to print correctly in Day view. The problem is that it will not print out the owners...
3
by: tstutting | last post by:
Hello, This is my first post and I'd really appreciate any help I can get. Sorry this is so long but it's complicated. I'm a USAF Officer and I'm attempting to make a shared MS Access DB that...
3
by: BLUE | last post by:
I've to call 2 web method from time to time so that the web service will do cleanup and sync jobs on a database. These methods can be called once every X days where X >= Y for the sync method...
0
by: amduke | last post by:
Hello, I'm using the Microsoft Scheduler to schedule 6 access application. Each application is scheduled on a different time starting at 03:00 am and the last one is scheduled 07:30 am. The...
3
by: assgar | last post by:
Hi I am having problem with my loping. I don't know if I have chosen the correct approach. GOAL: I need to insert into a table event types for a specific date range. The calendar the event...
14
lotus18
by: lotus18 | last post by:
Hello all I have these records on my Day Table for my complete database table please click here 1. M 2. T 3. W 4. TH 5. F 6. S
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

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.