Visual C++ ERRATA.WRI Part 1-2: Class Library ReferenceID: Q117739
|
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.
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.
const char* m_lpszClassName A null-terminated string containing the ASCII class name.
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.
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.
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.)
To run AppWizard, choose
to read as follows:
To run AppWizard, choose the AppWizard command on the Project menu in Visual Workbench.
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.")
m_pSet->m_strFilter = "CourseID = 'MATH101'";
For an explanation, see the "Caution" on page 31.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.
* 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.
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.
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 callsets only outputColumns to NULL. Params will be unaffected.SetFieldNull(NULL);
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.
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 query words: 1.50
Keywords : kb16bitonly
Version :
Platform :
Issue type :
Last Reviewed: July 29, 1999