I have a sqlite table that has a field named 'notes' and declared as WideString.
When I try to show the field in a DBGrid using XE3 C++ Builder, I get into problem.
I have written a GetText handler for the field in the ClientDataSet component, that looks like this (just for testing):
Code: Select all
void __fastcall TDataModule1::ribbonsCDSnotesGetText(TField *Sender, UnicodeString &Text,
bool DisplayText)
{
TField* field = dynamic_cast<TField*>(Sender);
if(field == ribbonsCDSnotes)
{
field->AsWideString;
Text = "Test2";
}
}
Any tips on how to get past this?
If I define the field as VARCHAR I don't have these problems.
Thanks,
tk