🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.ado
Article #1461

Create ADO Table

#1461
From: kev
Date: Wed, 23 Jun 2004 13:54
30 lines
1904 bytes
I am currently using a TTable, creating the fields dynamically at runtime
and using it to temporarily old data from ADO datasets.  This requires me to
install the BDE on the target system.  I would like to avoid having to be
tied to BDE if at all possible.  Is there a way for me to do so using one of
the ADO components?  I have tried several approaches with no success. A
sample of my current TTable code is below.  Thanks for any help.

    Table1->Active = false; // The Table component must not be active

    Table1->DatabaseName = "BCDEMOS";
    Table1->TableType = ttParadox;

    Table1->TableName = "MyTempTable";

    // describe the fields in the table
    Table1->FieldDefs->Clear();

    TFieldDef *pNewDef = Table1->FieldDefs->AddFieldDef();
    pNewDef->Name = "Location.";
    pNewDef->DataType = ftString;
    pNewDef->Required = false;
    pNewDef->Size = 8;
    .
    .
    .

    // Now that we have specified what we want, create the table
    Table1->CreateTable();

    Table1->Active = true; // The Table component must not be active
Technical Details
Message-ID: <40d98b79$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10698b,9588410ac5d71a1a,start
X-Google-Attributes: gid10698b,public
From: "kev" <kev@isp.com>
Newsgroups: borland.public.cppbuilder.database.ado
Subject: Create ADO Table
Date: Wed, 23 Jun 2004 08:54:02 -0500
Lines: 33
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
NNTP-Posting-Host: 65.116.27.178
Message-ID: <40d98b79$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1087998841 65.116.27.178 (23 Jun 2004 06:54:01 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail