You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
422 lines
15 KiB
422 lines
15 KiB
/*******************************************************************************
|
|
*
|
|
* (C) COPYRIGHT MICROSOFT CORP., 1998
|
|
*
|
|
* TITLE: StiScr.idl
|
|
*
|
|
* VERSION: 2.0
|
|
*
|
|
* AUTHOR: ReedB
|
|
*
|
|
* DATE: 6 Jan, 1998
|
|
*
|
|
* DESCRIPTION:
|
|
* IDL source for WIA device manager script interface. Visual Basic Scripting
|
|
* uses variants for all variables.
|
|
*
|
|
*******************************************************************************/
|
|
|
|
interface IWiaDevMgrDispatch;
|
|
interface IEnumWiaDevInfoDispatch;
|
|
interface IPropStorageDispatch;
|
|
interface IWiaItemDispatch;
|
|
interface IEnumWiaItemDispatch;
|
|
interface IEnumStatPropStgDispatch;
|
|
interface IEnumWiaDevCapsDispatch;
|
|
|
|
import "unknwn.idl";
|
|
import "oaidl.idl";
|
|
import "propidl.idl";
|
|
|
|
/*******************************************************************************
|
|
*
|
|
* WIA Device Manager Dispatch Interface
|
|
*
|
|
*******************************************************************************/
|
|
|
|
[
|
|
object,
|
|
uuid(f768d350-f9a4-11d1-9a0b-00c04fa36145),
|
|
helpstring("WIA Device Manager Dispatch Interface"),
|
|
pointer_default(unique),
|
|
oleautomation
|
|
]
|
|
|
|
interface IWiaDevMgrDispatch : IDispatch
|
|
{
|
|
[id(1), helpstring("Get an image and place data in clipboard")]
|
|
HRESULT GetImageClipboard(
|
|
[in] LONG hwndParent,
|
|
[in] LONG lDeviceType,
|
|
[in] LONG lFlags,
|
|
[in] LONG lIntent,
|
|
[in] BSTR bstrFormat,
|
|
[in, unique] IDispatch *pItem,
|
|
[out, retval] LONG *lResult);
|
|
|
|
[id(2), helpstring("Get an image and place data in a temporary file")]
|
|
HRESULT GetImageFile(
|
|
[in] LONG hwndParent,
|
|
[in] LONG lDeviceType,
|
|
[in] LONG lFlags,
|
|
[in] LONG lIntent,
|
|
[in] BSTR bstrFormat,
|
|
[in, unique] IDispatch *pItem,
|
|
[out, retval] BSTR *pbstrFileName);
|
|
|
|
[id(3), helpstring("Create an WIA device information enumerator")]
|
|
HRESULT EnumDeviceInfo(
|
|
[in] LONG lFlag,
|
|
[out, retval] IEnumWiaDevInfoDispatch **ppIEnum);
|
|
|
|
[id(4), helpstring("Create a WIA device object")]
|
|
HRESULT CreateDevice(
|
|
[in] BSTR bstrDeviceID,
|
|
[out, retval] IWiaItemDispatch **ppItem);
|
|
|
|
[id(5), helpstring("Present UI to select then create an WIA device")]
|
|
HRESULT SelectDevice(
|
|
[in] LONG hwndParent,
|
|
[in] LONG lDeviceType,
|
|
[in] LONG lFlags,
|
|
[out, retval] IWiaItemDispatch **ppItem);
|
|
|
|
[id(6), helpstring("Resisters pIDisp for the event notification")]
|
|
HRESULT RegisterEventCallbackInterface(
|
|
[in] LONG lFlags,
|
|
[in] BSTR bstrDevID,
|
|
[in] BSTR guidEventID,
|
|
[in] IDispatch *pIDisp);
|
|
|
|
};
|
|
|
|
/*******************************************************************************
|
|
*
|
|
* WIA Device Information Enumeration Dispatch Interface
|
|
*
|
|
*******************************************************************************/
|
|
|
|
[
|
|
object,
|
|
uuid(8e25d848-8949-11d2-b081-00c04fa36145),
|
|
helpstring("WIA Device Information Enumeration Interface"),
|
|
pointer_default(unique)
|
|
]
|
|
|
|
interface IEnumWiaDevInfoDispatch : IDispatch
|
|
{
|
|
[id(-4), propget, restricted, helpstring("Required enumerator for VB")]
|
|
HRESULT _NewEnum(
|
|
[out, retval] IUnknown **ppEnumVar);
|
|
|
|
[id(0), propget, helpstring("Returns the WiaDevInfo object of the given index")]
|
|
HRESULT Item(
|
|
[in] LONG lIndex,
|
|
[out, retval] VARIANT **retVal);
|
|
|
|
[id(1), helpstring("Gets the next WiaDevInfo object")]
|
|
HRESULT Next(
|
|
[in] ULONG celt,
|
|
[out] VARIANT *pProp,
|
|
[in,out,unique] ULONG *pceltFetched);
|
|
|
|
[id(2), helpstring("Skips the next WiaDevInfo object")]
|
|
HRESULT Skip(
|
|
[in] ULONG celt);
|
|
|
|
[id(3), helpstring("Resets to first WiaDevInfo object")]
|
|
HRESULT Reset(void);
|
|
|
|
[id(4), helpstring("Clone Device Info enumerator object, but returns the IEnumVARIANT interface")]
|
|
HRESULT Clone(
|
|
[out, retval] IEnumVARIANT **ppIEnum);
|
|
}
|
|
|
|
/*******************************************************************************
|
|
*
|
|
* Property Storage Dispatch Interface
|
|
*
|
|
*******************************************************************************/
|
|
|
|
[
|
|
object,
|
|
uuid(a2cef640-8f9e-11d2-b083-00c04fa36145),
|
|
helpstring("Property Storage Dispatch Interface"),
|
|
pointer_default(unique)
|
|
]
|
|
|
|
interface IPropStorageDispatch : IDispatch
|
|
{
|
|
HRESULT ReadMultiple(
|
|
[in] VARIANT *rgpspec,
|
|
[out, retval] VARIANT *rgpropvar);
|
|
|
|
HRESULT WriteMultiple(
|
|
[in] VARIANT *rgpspec,
|
|
[in] VARIANT *rgpropvar);
|
|
|
|
HRESULT ReadPropertyNames(
|
|
[in] VARIANT *pvPropSpec,
|
|
[out, retval] VARIANT *pvPropNames);
|
|
|
|
HRESULT Enum(
|
|
[out, retval] IEnumStatPropStgDispatch **ppEnum);
|
|
|
|
HRESULT WritePropertyNames(
|
|
[in] VARIANT *rgpropid,
|
|
[out] VARIANT *rglpwstrName);
|
|
|
|
HRESULT GetPropertyAttributes(
|
|
[in] VARIANT cpspec,
|
|
[in] VARIANT *rgpspec,
|
|
[out] VARIANT *rgflags,
|
|
[out] VARIANT *rgpropvar);
|
|
|
|
HRESULT GetCount(
|
|
[out] VARIANT *pulNumProps);
|
|
|
|
/* Not used currently
|
|
HRESULT GetPropertyStream(
|
|
[out] IStream **ppIStream);
|
|
|
|
HRESULT SetPropertyStream(
|
|
[in] IStream *pIStream);
|
|
*/
|
|
}
|
|
|
|
/*******************************************************************************
|
|
*
|
|
* WIA Property Storage Enumeration Dispatch Interface
|
|
*
|
|
*******************************************************************************/
|
|
|
|
[
|
|
object,
|
|
uuid(340bdb90-9f44-11d2-b08a-00c04fa36145),
|
|
helpstring("WIA Property Storage Enumeration Interface"),
|
|
pointer_default(unique)
|
|
]
|
|
|
|
interface IEnumStatPropStgDispatch : IDispatch
|
|
{
|
|
[id(-4), propget, restricted, helpstring("Required enumerator for VB")]
|
|
HRESULT _NewEnum(
|
|
[out, retval] IUnknown **ppEnumVar);
|
|
|
|
[id(0), propget, helpstring("Returns the item of the given index")]
|
|
HRESULT Item(
|
|
[in] LONG lIndex,
|
|
[out, retval] VARIANT **retVal);
|
|
|
|
[id(1), helpstring("Gets the next property")]
|
|
HRESULT Next(
|
|
[in] ULONG celt,
|
|
[out] VARIANT *pProp,
|
|
[in,out,unique] ULONG *pceltFetched);
|
|
|
|
[id(2), helpstring("Skips the next property")]
|
|
HRESULT Skip(
|
|
[in] ULONG celt);
|
|
|
|
[id(3), helpstring("Resets to first property")]
|
|
HRESULT Reset(void);
|
|
|
|
[id(4), helpstring("Clone property enumeration object, but returns the IEnumVARIANT interface")]
|
|
HRESULT Clone(
|
|
[out, retval] IEnumVARIANT **ppIEnum);
|
|
}
|
|
|
|
/*******************************************************************************
|
|
*
|
|
* IWiaItemDispatch Interface
|
|
*
|
|
*******************************************************************************/
|
|
|
|
[
|
|
object,
|
|
uuid(f4097433-9e68-11d2-b08a-00c04fa36145),
|
|
helpstring("WIA Device Item Interface"),
|
|
pointer_default(unique)
|
|
]
|
|
|
|
interface IWiaItemDispatch : IDispatch
|
|
{
|
|
[id(1), helpstring("Get item type")]
|
|
HRESULT GetItemType(
|
|
[out, retval] LONG *plItemType);
|
|
|
|
[id(2), helpstring("Analyze an item")]
|
|
HRESULT AnalyzeItem(
|
|
[in] LONG lFlags);
|
|
|
|
[id(3), helpstring("Get item enumerator")]
|
|
HRESULT EnumChildItems(
|
|
[out, retval] IEnumWiaItemDispatch **ppIEnumWiaItem);
|
|
|
|
[id(4), helpstring("Delete an item")]
|
|
HRESULT DeleteItem(
|
|
[in] LONG lFlags);
|
|
|
|
[id(5), helpstring("Create a new child item")]
|
|
HRESULT CreateChildItem(
|
|
[in] LONG lFlags,
|
|
[in] BSTR bstrItemName,
|
|
[in] BSTR bstrFullItemName,
|
|
[out, retval] IWiaItemDispatch **ppNewItem);
|
|
|
|
[id(7), helpstring("Issue a device command")]
|
|
HRESULT DeviceCommand(
|
|
[in] LONG lFlags,
|
|
[in] BSTR bstrCommand,
|
|
[out, retval] IWiaItemDispatch **pIWiaItem);
|
|
|
|
[id(8), helpstring("Display device data acquistion UI")]
|
|
HRESULT DeviceDlg(
|
|
[in] LONG hwndParent,
|
|
[in] LONG lFlags,
|
|
[in] LONG lIntent,
|
|
[out, retval] VARIANT *pIWiaItem);
|
|
|
|
[id(9), helpstring("search for item by name")]
|
|
HRESULT FindItemByName(
|
|
[in] LONG lFlags,
|
|
[in] BSTR bstrFullItemName,
|
|
[out, retval] IWiaItemDispatch **ppIWiaItem);
|
|
|
|
[id(10), helpstring("Get device root item")]
|
|
HRESULT GetRootItem(
|
|
[out, retval] IWiaItemDispatch **ppIWiaItem);
|
|
|
|
[id(11), helpstring("Read item properties")]
|
|
HRESULT ReadMultiple(
|
|
[in] VARIANT *rgpspec,
|
|
[out, retval] VARIANT *rgpropvar);
|
|
|
|
[id(12), helpstring("Write item properties")]
|
|
HRESULT WriteMultiple(
|
|
[in] VARIANT *rgpspec,
|
|
[in] VARIANT *rgpropvar);
|
|
|
|
[id(13), helpstring("Get capability enumerator")]
|
|
HRESULT EnumWiaDevCaps(
|
|
[in] ULONG ulFlags,
|
|
[out, retval] IEnumWiaDevCapsDispatch **ppIEnum);
|
|
};
|
|
|
|
/*******************************************************************************
|
|
*
|
|
* IEnumWiaItem Interface
|
|
*
|
|
*******************************************************************************/
|
|
|
|
[
|
|
object,
|
|
uuid(ff0bb94d-9e68-11d2-b08a-00c04fa36145),
|
|
helpstring("WIA Device Class Item Enumeration Interface"),
|
|
pointer_default(unique)
|
|
]
|
|
|
|
interface IEnumWiaItemDispatch : IDispatch
|
|
{
|
|
[id(-4), propget, restricted, helpstring("Required enumerator for VB")]
|
|
HRESULT _NewEnum(
|
|
[out, retval] IUnknown **ppEnumVar);
|
|
|
|
[id(0), propget, helpstring("Returns the item of the given index")]
|
|
HRESULT Item(
|
|
[in] LONG lIndex,
|
|
[out, retval] VARIANT **retVal);
|
|
|
|
[id(1), helpstring("Gets the next IWiaItem object")]
|
|
HRESULT Next(
|
|
[in] ULONG celt,
|
|
[out] VARIANT *pItem,
|
|
[in,out,unique] ULONG *pceltFetched);
|
|
|
|
[id(2), helpstring("Skips the specified number of IWiaItem objects")]
|
|
HRESULT Skip(
|
|
[in] ULONG celt);
|
|
|
|
[id(3), helpstring("Resets to first IWiaItemObject")]
|
|
HRESULT Reset(void);
|
|
|
|
[id(4), helpstring("Clone IWiaItem enumeration object and returns the IEnumVARIANT interface")]
|
|
HRESULT Clone(
|
|
[out, retval] IEnumVARIANT **ppIEnum);
|
|
}
|
|
|
|
/*******************************************************************************
|
|
*
|
|
* IEnumWiaDevCaps Interface
|
|
*
|
|
*******************************************************************************/
|
|
|
|
[
|
|
object,
|
|
uuid(05B40A3C-E6BC-11d2-B5C2-00C04F68C956),
|
|
helpstring("WIA Device Class Capability Enumeration Interface"),
|
|
pointer_default(unique)
|
|
]
|
|
|
|
interface IEnumWiaDevCapsDispatch : IDispatch
|
|
{
|
|
[id(-4), propget, restricted, helpstring("Required enumerator for VB")]
|
|
HRESULT _NewEnum(
|
|
[out, retval] IUnknown **ppEnumVar);
|
|
|
|
[id(0), propget, helpstring("Returns the item of the given index")]
|
|
HRESULT Item(
|
|
[in] LONG lIndex,
|
|
[out, retval] VARIANT **retVal);
|
|
|
|
[id(1), helpstring("Gets the next capability")]
|
|
HRESULT Next(
|
|
[in] ULONG celt,
|
|
[out] VARIANT *DevCap,
|
|
[in,out,unique] ULONG *pceltFetched);
|
|
|
|
[id(2), helpstring("Skips the next capability")]
|
|
HRESULT Skip(
|
|
[in] ULONG celt);
|
|
|
|
[id(3), helpstring("Resets to first capability")]
|
|
HRESULT Reset(void);
|
|
|
|
[id(4), helpstring("Clone capability enumeration object, but returns the IEnumVARIANT interface")]
|
|
HRESULT Clone(
|
|
[out, retval] IEnumVARIANT **ppIEnum);
|
|
}
|
|
|
|
/*******************************************************************************
|
|
*
|
|
* C O M P O N E N T D E S C R I P T I O N S
|
|
*
|
|
*******************************************************************************/
|
|
|
|
[
|
|
uuid(0c131077-0088-11d2-87ea-0060081ed811),
|
|
version(1.0),
|
|
helpstring("WIA Type Library Dispatch")
|
|
]
|
|
|
|
library WiaDevMgrDispatch
|
|
{
|
|
importlib("stdole32.tlb") ;
|
|
|
|
// WIA Device Manager Dispatch
|
|
[
|
|
uuid(4b97598e-006e-11d2-87ea-0060081ed811),
|
|
helpstring("WIA Device Manager Dispatch")
|
|
]
|
|
|
|
coclass WiaDevMgrDispatch
|
|
{
|
|
[default] interface IWiaDevMgrDispatch;
|
|
interface IEnumWiaDevInfoDispatch;
|
|
interface IPropStorageDispatch;
|
|
interface IWiaItemDispatch;
|
|
interface IEnumWiaItemDispatch;
|
|
interface IEnumStatPropStgDispatch;
|
|
interface IEnumWiaDevCapsDispatch;
|
|
};
|
|
};
|