DataSource Property
DataSource Property
This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.
Returns the IDataSource Interface on the object. This property is read-only.
Applies To
Type Library
Microsoft CDO for Exchange 2000 Library
DLL Implemented In
CDOEX.DLL
Syntax
[Visual Basic]Property DataSource As IDataSource
[C++]HRESULT get_DataSource(IDataSource** pVal);
Parameters
- pVal
Returned reference to an IDataSource Interface.
Remarks
This property returns the IDataSource interface on the object. If the object does not implement the IDataSource interface, the Component Object Model (COM) exception E_NOTIMPL is raised.
This property is intended to provide a mechanism for interface navigation with scripting languages that do not natively support interface navigation. For programming languages such as C++, Microsoft Visual Basic, and Microsoft Visual J++, the preferred way to navigate to the IDataSource interface on an object is to use native mechanisms, namely QueryInterface, the Set keyword, or type casting respectively. However, the DataSource property is valid to use from these languages as well.
Examples
[Visual Basic]
Dim iMsg as New CDO.Message Dim iDSrc as CDO.IDataSource
' The native way Set iDSrc = iMsg Set iDSrc = Nothing
' This works as well.
Set iDSrc = Bp.DataSource
Dim iMsg Dim iBp Set iMsg = CreateObject("CDO.Message") Dim iDSrc
' Navigate to DataSource in VBScript Set iDSrc = iBp.DataSource
Send us your feedback about the Microsoft Exchange Server 2003 SDK.
Build: June 2007 (2007.618.1)
© 2003-2006 Microsoft Corporation. All rights reserved. Terms of use.