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.

DOC: Can't Use ConnectName Property w/SQLGETPROP() Function


View products that this article applies to.

This article was previously published under Q137408

↑ Back to the top


Summary

Documents that ship with the Professional Edition of Microsoft Visual FoxPro version 3.0 for Windows and the Visual FoxPro Help file incorrectly list the ConnectName property as being available with the SQLGETPROP() function. However, using the ConnectName property with SQLGetProp results in this error:
Incorrect Property Name
The ConnectName property can be used with the CURSORGETPROP() function to return the result that would be expected with the SQLGETPROP() function.

↑ Back to the top


More information

Steps to Reproduce Behavior

  1. Use the ODBC Administrator to establish a data source, and assign it a name. One of the tables within Testdata.dbc can be copied to a type FOX2X to be used in this example as follows:
       USE C:\Vf\Samples\Data\Customer.dbf
       COPY TO odbctest TYPE FOX2X
    						
  2. After the data source has been set up with the ODBC Administrator, create and run a program containing this code:
       handle=SQLConnect("<Data_Source_Name>")
       =SQLExec(handle,"USE odbctest")
       =SQLExec(handle,"SELECT * FROM odbctest")
       ? SQLGetProp(handle,"ConnectName")       && This will produce the
                                                && error:
                                                && "Incorrect Property Name"
    						

↑ Back to the top


Keywords: KB137408, kbinterop, kbdocfix

↑ Back to the top

Article Info
Article ID : 137408
Revision : 3
Created on : 10/15/2003
Published on : 10/15/2003
Exists online : False
Views : 518