-
July 21st, 2013, 06:16 AM
#1
Getting error while retrieving value from ADO recordset.
I have a vc++ project file which reads data from access 2007 database.
I have successfully declared and opened connectionPtr and recordSetPtr objects.
The follwoing code is giving an error message that "item cannot be found in the collection"
stringVar = (recordSet->Fields->GetItem("[String]")->GetValue()).bstrVal;
If i replace "[String]" with "String" then above statement executed successfully.
How can i execute the above statement with "[String]" without errors?
Thanks in advance.
Regards,
Siva.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|