Hi, i am trying to converting a float value to display in a static text label.
Problem is how do i convert it to wchar_t , the type that static text label requires. Here a snippet so far:
I get error :
error C2664: 'irr::gui::IGUIElement::setText' : cannot convert parameter 1 from 'std::basic_string<_Elem,_Traits,_Ax>' to 'const wchar_t *'
[/code]
Last edited by julescoder on Sat Feb 20, 2010 3:46 pm, edited 1 time in total.
You have to use c_str() on the created wstring object, not on the stringstreams. Just take your first code and add it inside the outer braces. It's also almost what Bate suggested, just one constructor less (which is already implicit by the operator+)