Solved

Stable program

Posted on 2013-10-28
7
441 Views
Last Modified: 2013-10-28
Hi Experts,

Right now i have a Access DB running as a Task Scheduler. In other words, i have a form with a timer that executes (opens other Databases and runs Macros) 24/7 365 days a year.

The problem is that this Access DB, is not as stable as i was hoping for. I have made a current solution that closes the database by killing it in the Windows Task manager if it has frozen for more than 1 hour. (Don't ask for the solution it is complicated to explain)

I was then thinking of making a Desktop Application in Visual Studio to replace my Access Task Scheduler.

My question is: would a Application programmed correctly in Visual Studio be more stable than Access. I need the program to run 24/7 and if it crashes it should restart. How would i insure that and is it possible?
0
Comment
Question by:DCRAPACCESS
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 49

Expert Comment

by:Gustav Brock
ID: 39605015
You could try using the Task Scheduler of Windows.

Let it launch your Access app, start your processing from, say, the AutoExec macro, be done, and then quit Access.

/gustav
0
 

Author Comment

by:DCRAPACCESS
ID: 39605021
Hi Gustav,

I have a lot of criteria before opening a Access DB and executing  the Macros. So i would need a Program that i can trust running 24/7 and that is able to make a lot of tests before opening any database. I'm also controlling that the Access Databases don't crashes or ends i a loop and runs for more than 1 hour. So windows Task Scheduler is not an option as i see it.
0
 
LVL 49

Expert Comment

by:Gustav Brock
ID: 39605146
I see. The reliability of the running code would not change by this method, so if that is the problem, not the timer, then you will need something else to watch, as an Access app runs in one thread which cannot control itself.

That you could, I guess, solve with a .Net app with a "performer" and a "watcher" but it is a complete rewrite.

/gustav
0
Salesforce Made Easy to Use

On-screen guidance at the moment of need enables you & your employees to focus on the core, you can now boost your adoption rates swiftly and simply with one easy tool.

 
LVL 70

Expert Comment

by:Éric Moreau
ID: 39605226
>> would a Application programmed correctly in Visual Studio be more stable than Access.

I am not a fan of Access but if you introduce the same problem in you VS (C# or VB), you will the same issue of stability!
0
 
LVL 57

Accepted Solution

by:
Jim Dettman (Microsoft MVP/ EE MVE) earned 500 total points
ID: 39605318
A .Net app would only be more stable in the sense that it would be a true .EXE and not as sensitive to it's environment like MS Access is.  

 Outside of that, as the others have already said, you would continue to have the same problems your having now.

  I also wanted to kick in however that I have an MS Access App that runs as a task scheduler.   I wrote it because I had issues with certain Access versions/apps hanging at exit under certain OS's (there is a bug in A2000/2003 that generates a C0000005 at exit, which causes the Windows task scheduler to hang on occasion).

 I have it  running in/out of the system tray and have never had it freeze up and don't have any issues using it.

 So the bottom line is you need to look at what your executing.  Your apps need to be very robust, with error handling through out and you need to be following good practices, such as closing objects you open and setting any object variables to nothing.

  What I've found is that Access is actually an excellent tool for this type of use.  With an easy to use incrementally compiled VBA programming language, the ability to talk to other Office products with OLE automation, and being able to use and work with a large number of different datasources at the same time, make it a great "Swiss Army Knife" for getting things done quickly.

Jim.
0
 
LVL 57
ID: 39605329
BTW, here's what my task scheduler looks like.   As you can see, it's modeled after the Windows Task Scheduler.   While it's not as flexible in terms of options, it does handle all the basic scheduling tasks and then some.

It runs 24 x 7 without issue.

Jim.

Access based Task Scheduler
Task Schedule Options
0
 

Author Closing Comment

by:DCRAPACCESS
ID: 39606417
Thanks Jim. This was not what I was hoping to hear, but what i expected. I will only run Office vba code i many different databases, so i will keep using Access, and work even more on insuring all possible errors.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

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

You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

820 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