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

Threaded View

  1. #4
    Join Date
    Aug 2019
    Posts
    56

    Re: How to turn backslash to forward slash in windows environmental variable?

    Solved:
    Code:
    typedef std::basic_string<TCHAR> tstring;
     tstring pathbasic = tstring(programdata) + _T("\\myfile.txt");
     std::replace(pathbasic.begin(), pathbasic.end(), _T('\\'), _T('/'));
    Last edited by 2kaud; August 31st, 2019 at 08:03 AM.

Tags for this Thread

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