Sign in to follow this  
_damN_

Converting TCHAR* to char*?

Recommended Posts

Hi there... I have a function that requires me to convert a paramater to char* like so.. AddItem(m_hDEVICE, D3DDevTypeToString(pA->d3dDevs[d].d3dDevType), &pA->d3dDevs[d]); When i compile i get the error: "error C2664: 'AddItem' : cannot convert parameter 2 from 'TCHAR *' to 'char *'" Does someone have an easy way that i can convert parameter 2 from TCHAR* to char*? Thanks!

Share this post


Link to post
Share on other sites
Most easiest way is to change C++ project settings - set "Character Set" to "Use Multi-Byte Character Set".

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this