IXlsPivotTableDatasource
COM interface ( getting help with interfaces )

 

interface IXlsPivotTableDatasource : IDispatch
{
  [id(1),propput] HRESULT Range([in]BSTR dataRange);
  [id(1),propget] HRESULT Range([out, retval]BSTR* dataRange);
  [id(2),propput] HRESULT ExternalWorksheet([in]IXlsWorksheet* worksheet);
  [id(2),propget] HRESULT ExternalWorksheet([out, retval]IXlsWorksheet** worksheet);
  [id(3),propput] HRESULT RefreshOnLoad([in]BOOL bRefreshOnLoad);
  [id(3),propget] HRESULT RefreshOnLoad([out, retval]BOOL* bRefreshOnLoad);
  [id(4),propput] HRESULT RefreshEnabled([in]BOOL bRefreshEnabled);
  [id(4),propget] HRESULT RefreshEnabled([out, retval]BOOL* bRefreshEnabled);
  [id(5),propget] HRESULT DataConnection([out, retval]IXlsTableDataSource** dataconnection);
  [id(6)        ] HRESULT Refresh();

}

 

HRESULT Range([in]BSTR dataRange);
defines the source data range of the pivot table. This can be a cell area, a defined name or a table name.

HRESULT Range([out, retval]BSTR* dataRange);
returns the source data range of the pivot table.

HRESULT ExternalWorksheet([in]IXlsWorksheet* worksheet);
sets the external worksheet of the data range, if the data range is from another workbook.

HRESULT ExternalWorksheet([out, retval]IXlsWorksheet** worksheet);
retrieves the external worksheet of the data range, if the data range is from another workbook.

HRESULT RefreshOnLoad([in]BOOL bRefreshOnLoad);
sets whether or not the pivot table should refresh its datasource cache on load.

HRESULT RefreshOnLoad([out, retval]BOOL* bRefreshOnLoad);
retrieves whether or not the pivot table should refresh its datasource cache on load.

HRESULT RefreshEnabled([in]BOOL bRefreshEnabled);
sets whether or not the pivot table should enable the refresh of its datasource cache. Default is : true.

HRESULT RefreshEnabled([out, retval]BOOL* bRefreshEnabled);
retrieves whether or not the pivot table should enable the refresh of its datasource cache on load.

HRESULT DataConnection([out, retval]IXlsTableDataSource** dataconnection);
returns the data connection object, which is an alternative to a range-based data source.

HRESULT Refresh();
refreshes the data source.