Convert MFC CString to integer

后端 未结 11 2124
南旧
南旧 2020-12-08 13:15

How to convert a CString object to integer in MFC.

11条回答
  •  孤城傲影
    2020-12-08 13:52

    If you are using TCHAR.H routine (implicitly, or explicitly), be sure you use _ttoi() function, so that it compiles for both Unicode and ANSI compilations.

    More details: https://msdn.microsoft.com/en-us/library/yd5xkb5c.aspx

提交回复
热议问题