I need to create a wstring with the chars that have the following ascii values: 30, 29, 28, 27, 26, 25.
In VB6, I would do asc(30) + asc(29)+ etc…
What’s the C++ equivalent?
Thanks!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
An std::wstring is nothing more than an std::vector disguised as a string.
Therefore you should be able to use the push_back method, like this:
Don’t forget the 0-terminator !