defDir)
{
- SetColDefs (0, colName, DB_DATA_TYPE_VARCHAR, lookupCol, SQL_C_CHAR, LOOKUP_COL_LEN+1, false, false);
+ SetColDefs (0, colName, DB_DATA_TYPE_VARCHAR, lookupCol, SQL_C_CHAR, LOOKUP_COL_LEN+1, FALSE, FALSE);
} // Clookup()
int i = 0;
- SetColDefs (i, colName1, DB_DATA_TYPE_VARCHAR, lookupCol1, SQL_C_CHAR, LOOKUP_COL_LEN+1, false, false);
+ SetColDefs (i, colName1, DB_DATA_TYPE_VARCHAR, lookupCol1, SQL_C_CHAR, LOOKUP_COL_LEN+1, FALSE, FALSE);
if (wxStrlen(colName2) > 0)
- SetColDefs (++i, colName2, DB_DATA_TYPE_VARCHAR, lookupCol2, SQL_C_CHAR, LOOKUP_COL_LEN+1, false, false);
+ SetColDefs (++i, colName2, DB_DATA_TYPE_VARCHAR, lookupCol2, SQL_C_CHAR, LOOKUP_COL_LEN+1, FALSE, FALSE);
} // Clookup2()
wxBeginBusyCursor();
wxStrcpy(ListDB_Selection,wxT(""));
- widgetPtrsSet = false;
+ widgetPtrsSet = FALSE;
lookup = 0;
lookup2 = 0;
noDisplayCols = 1;
pLookUpOkBtn = new wxButton(this, LOOKUP_DIALOG_OK, wxT("&Ok"), wxPoint(113, 222), wxSize( 70, 35), 0, wxDefaultValidator, wxT("LookUpOkBtn"));
pLookUpCancelBtn = new wxButton(this, LOOKUP_DIALOG_CANCEL, wxT("C&ancel"), wxPoint(212, 222), wxSize( 70, 35), 0, wxDefaultValidator, wxT("LookUpCancelBtn"));
- widgetPtrsSet = true;
+ widgetPtrsSet = TRUE;
// Query the lookup table and display the result set
lookup = new Clookup(tableName, colName, pDb, defDir);
pLookUpSelectList->SetSelection(0);
// Make the OK activate by pressing Enter
- if (pLookUpSelectList->Number())
+ if (pLookUpSelectList->GetCount())
pLookUpOkBtn->SetDefault();
else
{
pLookUpCancelBtn->SetDefault();
- pLookUpOkBtn->Enable(false);
+ pLookUpOkBtn->Enable(FALSE);
}
// Display the dialog window
// 1) 2 columns rather than one
// 2) The ability to select DISTINCT column values
//
-// Only set distinctValues equal to true if necessary. In many cases, the constraints
+// Only set distinctValues equal to TRUE if necessary. In many cases, the constraints
// of the index(es) will enforce this uniqueness. Selecting DISTINCT does require
// overhead by the database to ensure that all values returned are distinct. Therefore,
// use this ONLY when you need it.
wxStrcpy(ListDB_Selection,wxT(""));
wxStrcpy(ListDB_Selection2,wxT(""));
- widgetPtrsSet = false;
+ widgetPtrsSet = FALSE;
lookup = 0;
lookup2 = 0;
noDisplayCols = (wxStrlen(dispCol2) ? 2 : 1);
pLookUpOkBtn = new wxButton(this, LOOKUP_DIALOG_OK, wxT("&Ok"), wxPoint(113, 222), wxSize(70, 35), 0, wxDefaultValidator, wxT("LookUpOkBtn"));
pLookUpCancelBtn = new wxButton(this, LOOKUP_DIALOG_CANCEL, wxT("C&ancel"), wxPoint(212, 222), wxSize(70, 35), 0, wxDefaultValidator, wxT("LookUpCancelBtn"));
- widgetPtrsSet = true;
+ widgetPtrsSet = TRUE;
// Query the lookup table and display the result set
lookup2 = new Clookup2(tableName, dispCol1, dispCol2, pDb, defDir);
{
lookup2->SetOrderByClause(orderBy);
lookup2->SetWhereClause(where);
- if (!lookup2->Query(false, distinctValues))
+ if (!lookup2->Query(FALSE, distinctValues))
{
wxMessageBox(wxT("ODBC error during Query()"),wxT("ODBC Error..."));
Close();
pLookUpSelectList->SetSelection(0);
// Make the OK activate by pressing Enter
- if (pLookUpSelectList->Number())
+ if (pLookUpSelectList->GetCount())
pLookUpOkBtn->SetDefault();
else
{
pLookUpCancelBtn->SetDefault();
- pLookUpOkBtn->Enable(false);
+ pLookUpOkBtn->Enable(FALSE);
}
pLookUpOkBtn->Enable(allowOk);
void ClookUpDlg::OnClose(wxCloseEvent& event)
{
- widgetPtrsSet = false;
- GetParent()->Enable(true);
+ widgetPtrsSet = FALSE;
+ GetParent()->Enable(TRUE);
if (lookup)
delete lookup;
while (wxIsBusy()) wxEndBusyCursor();
event.Skip();
-// return true;
+// return TRUE;
} // ClookUpDlg::OnClose