i'm trying to "compile" an Access ADP file to obtain an ADE with a small vbs script.
Option Explicit
Const acCmdMakeMDEFile = 603
Const msoAutomationSecurityLow = 1
Dim AccessADP
Set AccessADP = CreateObject("Access.Application")
AccessADP.AutomationSecurity = msoAutomationSecurityLow
AccessADP.visible=false
AccessADP.OpenCurrentDataBase(SourceOfADP)
I need to call one sub and one function which are written inside the ADP...for the sub no problem
AccessADP.Run "nameOfTheSub"
but i'm not able to use the function (that has to return one numeric value). The Access function is very simple
public function getValue() as Integer
getValue=10
end function
none of these solutions works for me
dim returnValue
set returnValue = AccessADP.Run "getValue"
dim returnValue
returnValue = AccessADP.Run "getValue"
any ideas to catch the return value from the function from vbs?
thanks in advance