CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3

Thread: Transfers

  1. #1
    Join Date
    Jun 2009
    Posts
    18

    Transfers

    Hello, in Visual Studio only beginning.
    And I can come here to convert between both types. I tried for example:



    char* er; String^ pom;

    er="NO";

    pom=Convert::ToString(er);

    so for me to pom write : True;




    Please advice on how to convert char <=> String, string <=> integer, thank you!

  2. #2
    Join Date
    Jul 2002
    Posts
    2,543

    Re: Transfers

    pom = Marshal::PtrToStringAnsi(IntPtr((void*)er));

    Integer to string: use ToString method.
    String to integer: use Int32::Parse method.

  3. #3
    Join Date
    Jun 2009
    Posts
    18

    Re: Transfers

    Thank you very Alex F !!!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured