I have got it working, but using an old copy of msscript.ocx that did came with VB6 (in my Windows 10 system, there is a registered one in C:\Windows\SysWOW64\msscript.ocx, but for some reason unknown to me it it doesn't work).
'#CONSOLE ON
#define UNICODE
#INCLUDE ONCE "windows.bi"
#include once "Afx/AfxCOM.inc"
#include once "Afx/CVAR.inc"
using Afx
' // Dual interfaces - Forward references
TYPE IScriptControl AS IScriptControl_
CONST CLSID_ScriptControl = "{0E59F1D5-1FBE-11D0-8FF2-00A0D10038BC}"
CONST IID_IScriptControl = "{0E59F1D3-1FBE-11D0-8FF2-00A0D10038BC}"
' ########################################################################################
' Interface name: IScriptControl
' IID: {0E59F1D3-1FBE-11D0-8FF2-00A0D10038BC}
' Documentation string: Control to host scripting engines that understand the ActiveX Scripting interface
' Attributes = 4304 [&h000010D0] [Hidden] [Dual] [Nonextensible] [Dispatchable]
' Inherited interface = IDispatch
' Number of methods = 30
' ########################################################################################
#ifndef __IScriptControl_INTERFACE_DEFINED__
#define __IScriptControl_INTERFACE_DEFINED__
TYPE IScriptControlVTbl
QueryInterface AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL riid AS CONST IID CONST PTR, BYVAL ppvObj AS ANY PTR PTR) AS HRESULT
AddRef AS FUNCTION (BYVAL this AS IScriptControl PTR) AS ULONG
Release AS FUNCTION (BYVAL this AS IScriptControl PTR) AS ULONG
GetTypeInfoCount AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL pctinfo AS UINT PTR) AS HRESULT
GetTypeInfo AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL iTInfo AS UINT, BYVAL lcid AS LCID, BYVAL ppTInfo AS ITypeInfo PTR PTR) AS HRESULT
GetIDsOfNames AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL iTInfo AS UINT, BYVAL lcid AS LCID, BYVAL ppTInfo AS ITypeInfo PTR PTR) AS HRESULT
Invoke AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL dispIdMember AS DISPID, BYVAL riid AS CONST IID CONST PTR, BYVAL lcid AS LCID, BYVAL wFlags AS WORD, BYVAL pDispParams AS DISPPARAMS PTR, BYVAL pVarResult AS VARIANT PTR, BYVAL pExcepInfo AS EXCEPINFO PTR, BYVAL puArgErr AS UINT PTR) AS HRESULT
get_Language AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS BSTR PTR) AS HRESULT
put_Language AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS BSTR PTR) AS HRESULT
get_State AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS ANY PTR) AS HRESULT
put_State AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS ANY PTR) AS HRESULT
put_SitehWnd AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS LONG) AS HRESULT
get_SitehWnd AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS LONG PTR) AS HRESULT
get_Timeout AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS LONG PTR) AS HRESULT
put_Timeout AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS LONG) AS HRESULT
get_AllowUI AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS VARIANT_BOOL PTR) AS HRESULT
put_AllowUI AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS VARIANT_BOOL) AS HRESULT
get_UseSafeSubset AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS VARIANT_BOOL PTR) AS HRESULT
put_UseSafeSubset AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS VARIANT_BOOL) AS HRESULT
get_Modules AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS ANY PTR PTR) AS HRESULT
get_Error AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS ANY PTR PTR) AS HRESULT
get_CodeObject AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS ANY PTR) AS HRESULT
get_Procedures AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL rhs AS ANY PTR PTR) AS HRESULT
_AboutBox AS FUNCTION (BYVAL this AS IScriptControl PTR) AS HRESULT
AddObject AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL Name AS BSTR, BYVAL Object AS ANY PTR, BYVAL AddMembers AS VARIANT_BOOL = 0) AS HRESULT
Reset AS FUNCTION (BYVAL this AS IScriptControl PTR) AS HRESULT
AddCode AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL Code AS BSTR) AS HRESULT
Eval AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL Expression AS BSTR, BYVAL rhs AS VARIANT PTR) AS HRESULT
ExecuteStatement AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL Statement AS BSTR) AS HRESULT
Run AS FUNCTION (BYVAL this AS IScriptControl PTR, BYVAL ProcedureName AS BSTR, BYVAL Parameters AS ANY PTR, BYVAL rhs AS VARIANT PTR) AS HRESULT
END TYPE
TYPE IScriptControl_
lpVtbl AS IScriptControlVTbl PTR
END TYPE
' ########################################################################################
#endif
CoInitialize(NULL)
DIM pSC AS IScriptControl PTR
'pSC = AfxNewCom("MSScriptControl.ScriptControl") ' The installed msscript.ocx in Win10 does not work
pSC = AfxNewCom(Exepath & "\" & "msscript.ocx", CLSID_ScriptControl, IID_IScriptControl)
IF pSC = NULL THEN END
DIM hr AS HRESULT
DIM cbsLanguage AS CBSTR = "VBScript"
hr = pSC->lpVtbl->put_Language(pSC, cbsLanguage)
DIM cvRes AS CVAR
DIM cbsExpr AS CBSTR = "(3*4)"
hr = pSC->lpVtbl->Eval(pSC, cbsExpr, cvRes.vptr)
print cvRes
AfxSafeRelease(pSC)
CoUninitialize
PRINT
PRINT "Press any key..."
SLEEP