Click to See Complete Forum and Search --> : ADO with WFC sintax


ricos
August 17th, 2000, 06:15 AM
there is a bug with column creation.

_Catalog *tmpCatalog;
_Table *tmpTable;
_Recordset *tmpRecord;
Columns *tmpColumns;
Tables *tmpTables;

strConnection = L"Provider=Microsoft.Jet.OLEDB.4.0;"
L"Jet OLEDB:Engine Type =4;"
L"Data Source="+CString(accessFile)+";";

tmpCatalog = new _Catalog;
tmpCatalog->Create(strConnection);

/// Create Structure
tmpTable = new _Table;
tmpTable->SetName("DalexObject");

tmpColumns = (Columns*)tmpTable->GetColumns();
tmpColumns->Append(COleVariant("ClassProperty"),205,0);
tmpColumns->Append(COleVariant("MasterProperty"),205,0);

tmpTables = (Tables*)tmpCatalog->GetTables();
var.pdispVal = (IDispatch*)tmpTable;
tmpTables->Append(COleVariant(var));