[AccessD] C2DbWakeup

John W. Colby jwcolby at colbyconsulting.com
Sat Jan 17 13:44:13 CST 2004


Fascinating.  This runs a program called mstrProcessName I assume?

I think I would put that at the supervisor level (or event the form level)
so that the supervisor (or form) could decide whether the thing needing
awakened is an external program or not.

Nice idea though.

John W. Colby
www.ColbyConsulting.com

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Michael R
Mattys
Sent: Saturday, January 17, 2004 2:23 PM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] C2DbWakeup


John,

I just had a look at your demo and just wanted to offer
that you could put in something like the following

'Module
Public Declare Function WinExec Lib "kernel32" _
(ByVal lpCmdLine As String, ByVal nCmdShow As Long) As Long

'clsWakeUp
Function Run(lstrProcessName) As Boolean
    'Hasn't run today so check if the time is > mdetTimeToRun
    If time() > mdteTimeToRun Then
        If Date > mdteLastRan Then
            Dim lngProc As Long
            lngProc = WinExec(mstrProcessName, 1)
            'Mark mdteLastRun = Now()
            mdteLastRan = Date
            'and return true
            lstrProcessName = mstrProcessName
            Run = True
        End If
    End If
End Function

Michael R. Mattys
Try MattysMapLib for MapPoint at
www.mattysconsulting.com



----- Original Message -----
From: "John W. Colby" <jwcolby at colbyconsulting.com>
To: "AccessD" <AccessD at databaseadvisors.com>
Sent: Saturday, January 17, 2004 1:01 PM
Subject: [AccessD] C2DbWakeup


> For anyone interested, the wakeup class demo requested by Hengky Lie has
> been added to my web site.  Click the fifth button from the bottom -
> Withevents demo.  The bottom item on the page C2DbWakeup.zip will download
> the demo to your computer.
>
> John W. Colby
> www.ColbyConsulting.com
>
>
> _______________________________________________
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com

_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com





More information about the AccessD mailing list