Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

PRB: Error When You Use MS Data Shape Provider in Data Environment

View products that this article applies to.

This article was previously published under Q193347

↑ Back to the top


When you try to use the Query Designer against the MS Shape Provider in the Data Environment, the following error message is returned:
Query Designer encountered a ADODB.Properties error:
Query Designer encountered a ADODB.Properties error:
Query Designer encountered a ADODB.Properties error:
ADO could not find the object in the collection corresponding to the
name or ordinal reference requested by the application.(11)
Upon clicking OK, a second error message is returned:
Object Variable or With block variable not set.

↑ Back to the top


This behavior is by design.

↑ Back to the top

More information

The Query Designer cannot be used to build hierarchical queries against the shape provider. If you want to build a hierarchical query via the DE, you can use the Query Designer for each separate query, and then use the property pages on the data environment to specify the relationship between the queries. The Query Designer is not able to talk directly to the DataShape provider.

Steps to Reproduce Behavior

This sample uses a dsn named NWind that connects to the Nwind.MDB that comes with Visual Basic.
  1. Create a Standard EXE project in Visual Basic. Form1 is created default.
  2. Add a data environment.
  3. For connection1 properties, set provider to MS Data Shape, and set the data source to Nwind (you can just type the dsn name here).
  4. Click OK.
  5. Add a new command.
  6. For Command1 properties select SQL Statement, then click on SQL Builder.
  7. Note that the Error messages above are returned.

↑ Back to the top


For more information about the Visual Basic Data Environment or the MSDataShape OLE DB provider, please refer to your Visual Basic online documentation.

↑ Back to the top

Keywords: kbprovider, kbdataenv, kbdatabase, kbdesigner, kbprb, KB193347

↑ Back to the top

Article Info
Article ID : 193347
Revision : 4
Created on : 3/14/2005
Published on : 3/14/2005
Exists online : False
Views : 447