c++ - What can you use to cast an int/float to a wchar_t*? -


How do you do if you have int or float It can promote it without using external libraries like wchar_t * in

< Pre> std :: wostringstream oss; Int i = 1212; // or float F = 1212.0F; Oss & lt; & Lt; I; // oss & lt; & Lt; F; Std :: wstring ws = oss.str (); Const wchar_t * cwp = ws.c_str (); // const wchar_t * std :: vector & lt; Wchar_t & gt; Buf (cwp, cwp + (wc.size (+ 1)); Wchar_t * wp = & amp; Buf [0]; // wchar_t *

Comments

Popular posts from this blog

c# - How to capture HTTP packet with SharpPcap -

jquery - SimpleModal Confirm fails to submit form -

php - Multiple Select with Explode: only returns the word "Array" -