I am using this code to format WideString but with no success! It prints unexpecting results :(
here is my code
WideString s;
dep=new TStringList();
while(!DM->tDepPln->Eof)
{
//where tDepPlnFltNo is mysql field type of WideString
s.sprintf(L"%-11S",DM->tDepPlnFltNo->AsWideString);
dep->Add(s);
DM->tDepPln->Next();
}
when I use s.sprintf(L"%-11S","blablabla");
it works but when i set to mysql field type of WideString it's not!!
I think the problem is with conversion!
How to correct it ???