Hi Guys,
I am facing a weird problem to put the database query in CString Format with
Unicode defined.
I am giving a simple example of my problem.
CString str1;
int value = 123;
str1.Format(_T("select * from Table Where Max > %d"), value);
Getting output only 1st character of entire string.
Output-> "s"
instead of -> "select * from Table Where Max > 123"
I also tried this one but It's not getting integer variable and displaying like this:
str1.Format((LPCTSTR)("select * from Table Where Max > %d"), value);
OutPut-> "select * from Table Where Max > %d"
Please give me some solution because I tried everything but I didn't get where I did
mistake.