Product Documentation

c-treeDB API for C# - Developers Guide

Previous Topic

Next Topic

Finding Records by ROWID

A record can be quickly located if the rowid for that record is known by calling CTRecord.FindRowid(). CTRecord.FindRowid() take as its parameters the ROWID value and the find mode.

// find record with rowid of 1000

CTRecord ARecord = new CTRecord(ATable);

try

{

if (ARecord.FindRowid(1000, FIND_MODE.EQ))

Console.Write("Record found\n");

else

Console.Write("No record found\n");

}

catch (CTException err)

{

Console.Write("Find Rowid failed with error {0}\n", err.GetErrorCode());

}

TOCIndex