2 * Copyright 2015 Jacek Caban for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #pragma makedep regtypelib
24 helpstring("Microsoft Script Control 1.0"),
25 uuid(0e59f1d2
-1fbe
-11d0
-8ff2
-00a0d10038bc
),
28 library MSScriptControl
30 importlib
("stdole2.tlb");
35 } ScriptControlStates
;
39 uuid(70841c73
-067d
-11d0
-95d8
-00a02463ab28
),
45 interface IScriptProcedure
: IDispatch
{
46 [id(DISPID_VALUE
), propget]
47 HRESULT Name
([out, retval] BSTR *pbstrName
);
50 HRESULT NumArgs
([out, retval] long *pcArgs
);
53 HRESULT HasReturnValue
([out, retval] VARIANT_BOOL *pfHasReturnValue
);
58 uuid(70841c71
-067d
-11d0
-95d8
-00a02463ab28
),
64 interface IScriptProcedureCollection
: IDispatch
{
65 [id(DISPID_NEWENUM
), propget]
66 HRESULT _NewEnum
([out, retval] IUnknown
**ppenumProcedures
);
68 [id(DISPID_VALUE
), propget]
71 [out, retval] IScriptProcedure
**ppdispProcedure
);
74 HRESULT Count
([out, retval] long *plCount
);
79 uuid(70841c70
-067d
-11d0
-95d8
-00a02463ab28
),
85 interface IScriptModule
: IDispatch
{
86 [id(DISPID_VALUE
), propget]
87 HRESULT Name
([out, retval] BSTR *pbstrName
);
90 HRESULT CodeObject
([out, retval] IDispatch
**ppdispObject
);
93 HRESULT Procedures
([out, retval] IScriptProcedureCollection
**ppdispProcedures
);
96 HRESULT AddCode
([in] BSTR Code
);
100 [in] BSTR Expression
,
101 [out, retval] VARIANT *pvarResult
);
104 HRESULT ExecuteStatement
([in] BSTR Statement
);
108 [in] BSTR ProcedureName
,
109 [in] SAFEARRAY(VARIANT) *Parameters
,
110 [out, retval] VARIANT *pvarResult
);
115 uuid(70841c6f
-067d
-11d0
-95d8
-00a02463ab28
),
121 interface IScriptModuleCollection
: IDispatch
{
122 [id(DISPID_NEWENUM
), propget]
123 HRESULT _NewEnum
([out, retval] IUnknown
**ppenumContexts
);
125 [id(DISPID_VALUE
), propget]
128 [out, retval] IScriptModule
**ppmod
);
131 HRESULT Count
([out, retval] long *plCount
);
136 [in, optional] VARIANT *Object,
137 [out, retval] IScriptModule
**ppmod
);
142 uuid(70841c78
-067d
-11d0
-95d8
-00a02463ab28
),
144 helpstring("Provides access to scripting error information"),
145 helpcontext(0x00113eb6),
150 interface IScriptError
: IDispatch
{
151 [id(0x00c9), propget]
152 HRESULT Number
([out, retval] long *plNumber
);
154 [id(0x00ca), propget]
155 HRESULT Source([out, retval] BSTR *pbstrSource
);
157 [id(0x00cb), propget]
158 HRESULT Description
([out, retval] BSTR *pbstrDescription
);
160 [id(0x00cc), propget]
161 HRESULT HelpFile([out, retval] BSTR *pbstrHelpFile
);
163 [id(0x00cd), propget]
164 HRESULT HelpContext([out, retval] long *plHelpContext
);
166 [id(0xfffffdfb), propget]
167 HRESULT Text
([out, retval] BSTR *pbstrText
);
169 [id(0x00ce), propget]
170 HRESULT Line
([out, retval] long *plLine
);
172 [id(0xfffffdef), propget]
173 HRESULT Column
([out, retval] long *plColumn
);
181 uuid(0e59f1d3
-1fbe
-11d0
-8ff2
-00a0d10038bc
),
187 interface IScriptControl
: IDispatch
{
188 [id(0x05dc), propget] HRESULT Language
([out, retval] BSTR *pbstrLanguage
);
189 [id(0x05dc), propput] HRESULT Language
([in] BSTR pbstrLanguage
);
191 [id(0x05dd), propget] HRESULT State
([out, retval] ScriptControlStates
*pssState
);
192 [id(0x05dd), propput] HRESULT State
([in] ScriptControlStates pssState
);
194 [id(0x05de), propput] HRESULT SitehWnd
([in] long rhs
);
195 [id(0x05de), propget] HRESULT SitehWnd
([out, retval] long *rhs
);
197 [id(0x05df), propget] HRESULT Timeout
([out, retval] long *plMilleseconds
);
198 [id(0x05df), propput] HRESULT Timeout
([in] long plMilleseconds
);
200 [id(0x05e0), propget] HRESULT AllowUI
([out, retval] VARIANT_BOOL *pfAllowUI
);
201 [id(0x05e0), propput] HRESULT AllowUI
([in] VARIANT_BOOL pfAllowUI
);
203 [id(0x05e1), propget] HRESULT UseSafeSubset
([out, retval] VARIANT_BOOL *pfUseSafeSubset
);
204 [id(0x05e1), propput] HRESULT UseSafeSubset
([in] VARIANT_BOOL pfUseSafeSubset
);
206 [id(0x05e2), propget] HRESULT Modules
([out, retval] IScriptModuleCollection
**ppmods
);
208 [id(0x05e3), propget] HRESULT Error
([out, retval] IScriptError
**ppse
);
210 [id(0x03e8), propget] HRESULT CodeObject
([out, retval] IDispatch
**ppdispObject
);
212 [id(0x03e9), propget] HRESULT Procedures
([out, retval] IScriptProcedureCollection
**ppdispProcedures
);
220 [in] IDispatch
*Object,
221 [in, optional, defaultvalue(0)] VARIANT_BOOL AddMembers
);
227 HRESULT AddCode
([in] BSTR Code
);
231 [in] BSTR Expression
,
232 [out, retval] VARIANT *pvarResult
);
235 HRESULT ExecuteStatement
([in] BSTR Statement
);
239 [in] BSTR ProcedureName
,
240 [in] SAFEARRAY(VARIANT) *Parameters
,
241 [out, retval] VARIANT *pvarResult
);
245 uuid(8b167d60
-8605-11d0
-abcb
-00a0c90fffc0
),
248 dispinterface DScriptControlSource
{
251 [id(0x0bb8)] void Error
();
252 [id(0x0bb9)] void Timeout
();
256 uuid(0e59f1da
-1fbe
-11d0
-8ff2
-00a0d10038bc
),
260 [default] interface IScriptProcedure
;
264 uuid(0e59f1db
-1fbe
-11d0
-8ff2
-00a0d10038bc
),
268 [default] interface IScriptProcedureCollection
;
272 uuid(0e59f1dc
-1fbe
-11d0
-8ff2
-00a0d10038bc
),
276 [default] interface IScriptModule
;
280 uuid(0e59f1dd
-1fbe
-11d0
-8ff2
-00a0d10038bc
),
284 [default] interface IScriptModuleCollection
;
288 uuid(0e59f1de
-1fbe
-11d0
-8ff2
-00a0d10038bc
),
292 [default] interface IScriptError
;
296 helpstring("ScriptControl Object"),
297 uuid(0e59f1d5
-1fbe
-11d0
-8ff2
-00a0d10038bc
),
298 threading
(apartment
),
299 progid
("MSScriptControl.ScriptControl.1"),
300 vi_progid
("MSScriptControl.ScriptControl")
302 coclass ScriptControl
{
303 [default] interface IScriptControl
;
304 [default, source] dispinterface DScriptControlSource
;