08-12-2002, 08:56 AM
There is a doubt which i have. I am developing a site using ASP and MS-Access. I have a particular piece of code which i want should be executed once every day. I dont own a server and hosted the site on some ISP server by buying space. Had i used SQL Server i could have created a job or something to achieve this. But i am using MS-Access. Can somebody help?
Thanks in advance
08-12-2002, 09:14 AM
Your best bet is to create a hidden web page that does the
process when it is hit, then schedule a computer you control to
hit that page once a day.
08-12-2002, 09:38 AM
how do we schedule the computer to hit the page?
08-12-2002, 10:20 AM
Create a standard project
Drop a timer on it
have the timer check once an hour to see if it is between midnight and 1:00am (or whatever time you want)
When it is, then something like this
Public Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
'Public Declare Function SetWindowPos Lib "user32" (ByVal hwnd As Long, ByVal hWndInsertAfter As Long, ByVal X As Long, ByVal Y As Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long
Private Sub ActivatePage()
Public Function OpenURL(ByVal URL As String) As Long
'Allows the user to open a URL in the default browser
OpenURL = ShellExecute(0&, vbNullString, URL, vbNullString, vbNullString, vbNormalFocus)
08-15-2002, 06:41 PM
whats the code do? does it need to be executed every day or just once before the first person sees it?
08-16-2002, 12:41 AM
You can just run the program once, which will then continue running in the background.