Andy Lacey
andy at minstersystems.co.uk
Mon Sep 14 14:32:49 CDT 2009
Hiya Darren
Yea like Jim I use Eval. Works a treat.
strWhatEver = rst!Field
Call Eval(strWhatever)
That sort of thing.
Cheers
Andy
-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Jim Dettman
Sent: 14 September 2009 13:31
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] A2K: Run a VBA Function whose name is stored in
atable
Checkout eval().
Jim.
-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Darren - Active
Billing
Sent: Sunday, September 13, 2009 8:11 PM
To: 'Access Developers discussion and problem solving'
Subject: [AccessD] A2K: Run a VBA Function whose name is stored in a table
Hi Team
How do you 'run' a VBA function in my Access dB whose name is stored in a
table?
Say I have a table called tblFunctions with 3 fields
Fieldnames are : FunctionID, IsToRun and FunctionName
The 1st Field = PK, 2nd field = Integer and 3rd = text
EG
Dim strFunctionToRun as string
strFunctionToRun = dlookup("[FunctionName]","tblFunctions", "IsToRun = -1")
Assume the results of strFunctionToRun is
say."f_SomeCoolFunctionThatDoesStuff"
How do I 'run' the results of strFunctionToRun??
IE how do I run "f_someCoolFunctionThatDoesStuff"
Many thanks in advance
DD
--
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