Visual C++ ERRATA.WRI Part 1-2: Class Library Reference

Last reviewed: July 22, 1997
Article ID: Q117739
1.50 WINDOWS kbreadme

The information in this article applies to:

  • Microsoft Visual C++ for Windows, version 1.5

SUMMARY

This article is a reproduction of parts 1 and 2 of the ERRATA.WRI file distributed with Microsoft Visual C++, version 1.5. The Visual C++ setup installs ERRATA.WRI in the MSVC\HELP directory.

MORE INFORMATION

Part 1: Notes on Class Library Reference

  • Page 32, File Manager Drag and Drop:

    Replace the last paragraph with the following:

          To enable file drag-and-drop in your application, AppWizard writes a
          call to the CWnd member function DragAcceptFiles (if you chose to
          assign a file extension to your document class) for your main frame
          window in your InitInstance. You can remove this call if you do not
          want to implement file drag-and-drop.
    
  • Page 577, CObject::GetRuntimeClass:

    Replace the second paragraph with the following:

          const char* m_lpszClassName A null-terminated string containing the
          ASCII class name.
    
  • Page 737, CScrollView::SetScaleToFitSize(SIZE szTotal):

    Replace the last sentence in the first paragraph with the following:

          Usually cx and cy are greater than zero. However, if you wish to
          invert either the x-axis or the y-axis (as is common when emulating
          standard mapping modes such as MM_LOENGLISH), specify a negative cx
          or cy.
    

Part 2: Notes on Database Classes

  • Page 10:

    In Table 2.1, column 3 of the Enrollment row, place an asterisk after StudentID. The full primary key for the Enrollment table is CourseID + SectionID + StudentID.

  • Page 14:

    In the second full paragraph, which begins "A record view is a specialized view class that...", replace the sentence

          CRecordView supports end-user navigation through records, one at a
          time, using Move First, Move Next, Move Previous, and Move Last
          commands.
    

    with this sentence:

          CRecordView supports end-user navigation through records, one at a
          time, using the Move First, Move Next, Move Previous, and Move Last
          commands of the associated CRecordset object.
    
  • Page 34:

    Change the last line on the page from

          pDoc->m_courseSet.m_strSort = "CourseID:;
    

    to read as follows:

          pDoc->m_courseSet.m_strSort = "CourseID";
    

    (That is, change the colon to a double quotation mark.)

  • Page 53:

    In the second paragraph of the "AppWizard" article, complete the sentence

          To run AppWizard, choose
    

    to read as follows:

          To run AppWizard, choose the AppWizard command on the Project menu in
          Visual Workbench.
    
  • Page 86:

    In the third full paragraph, replace "CRecordset::Open" with "CRecordset::dynaset".

  • Page 114:
  • The second line of text at the top of the page reads:

          you get a recordset that is dynamic but doesn't allow updates or
          backward scrolling
    

    Delete the words "is dynamic but". (A forward-only recordset allows forward scrolling only, does not allow updates, and should not be considered "dynamic.")

- Page 122:

   Step 2 of the procedure "To specify a filter for a recordset object"
   contains two lines of code. In both code lines, add single quotation
   marks around the literal string "MATH101". For example:

      m_pSet->m_strFilter = "CourseID = 'MATH101'";

   For an explanation, see the "Caution" on page 31.

  • Page 172:

    Under the section "SQL Statement Construction," after the following paragraph:

          To override the default SELECT statement, pass a string containing a
          complete SELECT statement when you call Open. Instead of constructing
          its own default string, the recordset uses the string you supply. If
          your replacement statement contains a WHERE clause, don't specify a
          filter in m_strFilter because you would then have two filter
          statements. If your replacement statement contains an ORDER BY
          clause, don't specify a sort in m_strSort so that you will not have
          two sort statements.
    

    add the following "Caution" note:

          *Caution*
    

          In the Enroll tutorial application, filter strings typically use a
          parameter placeholder, "?", rather than assigning a specific literal
          value, such as "MATH101", at compile time. If you do use literal
          strings in your filters (or other parts of the SQL statement), you
          may have to "quote" such strings with a DBMS-specific "literal
          prefix" and "literal suffix" character (or characters). For example,
          the code in this section uses a single quote character to bracket the
          value assigned as the filter, "MATH101". You may also encounter
          special syntactic requirements for operations such as outer joins,
          depending on your DBMS. Use ODBC functions to obtain this information
          from your driver for the DBMS. For example, call ::SQLGetTypeInfo for
          a particular data type, such as SQL_VARCHAR, to request the
          LITERAL_PREFIX and LITERAL_SUFFIX characters. If you are writing
          database-independent code, see Appendix C in the ODBC Programmer's
          Reference for detailed syntax information.
    
  • Page 201:

    In the list of values that can be returned in the CDBException::m_nRetCode data member, add the following values (alphabetically):

          * AFX_SQL_ERROR_DATA_TRUNCATED  You requested more data than you have
          provided storage for. For information on increasing the provided data
          storage for CString or CByteArray data types, see the nMaxLength
          argument for RFX_Text and RFX_Binary under "Macros and Globals."
    

          * AFX_SQL_ERROR_LOCK_MODE_NOT_SUPPORTED  Your request to lock records
          for update could not be fulfilled because your ODBC driver does not
          support locking.
    

          * AFX_SQL_ERROR_NO_POSITIONED_UPDATES  Your request for a dynaset
          could not be fulfilled because your ODBC driver does not support
          positioned updates.
    

          * AFX_SQL_ERROR_ODBC_V2_REQUIRED  Your request for a dynaset could
          not be fulfilled because a Level 2-compliant ODBC driver is required.
    
  • Page 221:

    In the description of the CRecordset::GetStatus member function, change the description of m_lCurrentRecord to the following:

          Contains the zero-based index of the current record in the recordset,
          if known. If the index cannot be determined, this member contains
          AFX_CURRENT_RECORD_UNDEFINED (-2). If IsBOF is TRUE (empty recordset
          or attempt to scroll before first record) then m_lCurrentRecord is
          set to AFX_CURRENT_RECORD_BOF (-1). If on the first record, then it
          is set to 0, second record 1, and so on.
    
  • Pages 224, 225, 234, and 235:

    Add the indicated information below to the Remarks for the CRecordset functions listed below:

          IsFieldDirty            p. 224
          IsFieldNull             p. 225
          IsFieldNullable         p. 225
          SetFieldDirty           p. 234
          SetFieldNull            p. 235
    
       Add the following:
    
          Using NULL for the first argument of the function will apply the
          function only to outputColumns, not params. For example, the call
    
             SetFieldNull(NULL);
    
          sets only outputColumns to NULL. Params will be unaffected.
    
          To work on params, you must supply the actual address of the
          individual param you want to work on (i.e.
          SetFieldNull(&m_strParam)). This means you cannot set all params
          NULL, as you can with outputColumns.
    
    
  • Page 230:

    In the description of the forwardOnly option for the nOpenType parameter to the CRecordset::Open member function, delete the word "dynaset". (A forward-only recordset allows forward scrolling only, does not allow updates, and should not be considered a dynaset.)


  • Additional reference words: 1.50
    KBCategory: kbreadme
    KBSubcategory: VCGenIss
    Keywords : kb16bitonly


    THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

    Last reviewed: July 22, 1997
    © 1998 Microsoft Corporation. All rights reserved. Terms of Use.