🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

cancel deleting of record

#820
From: Borut
Date: Wed, 25 May 2005 14:55
21 lines
1359 bytes
Hello!

I am using BCB6, ADO, MSSQL, DBNavigator
Is it possible to prevent a record to be deleted if user clicks Delete 
button on Navigator.

I tried like this, but a record is deleted anyway:

void __fastcall TDataModule1::NarocilniceBeforeDelete(TDataSet *DataSet)
{

   if(DataModule1->ShemaT->RecordCount > 0)
   {
      ShowMessage("Delete data in Shema first!");
      DataSet->Cancel();
   }
}

Thx in advance
Borut
Slovenia
Technical Details
Message-ID: <429491d8@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news2.google.com!news.maxwell.syr.edu!news-out.nntp.be!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 10698b,769db7213d949363,start
X-Google-Attributes: gid10698b,public
X-Google-Language: ENGLISH,ASCII-7-bit
Reply-To: "Borut" <borut@bokosoft.si>
From: "Borut" <borut@bokosoft.si>
Newsgroups: borland.public.cppbuilder.database.ado
Subject: cancel deleting of record
Date: Wed, 25 May 2005 16:55:18 +0200
Lines: 23
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 213.157.239.90
Message-ID: <429491d8@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1117032920 213.157.239.90 (25 May 2005 07:55:20 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news2.google.com!news.maxwell.syr.edu!news-out.nntp.be!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail