Do you have a typical platform dependent issue you're battling with ? Ask it here. Make sure you mention your platform, compiler, and wxWidgets version.
- In need of some credit
- Posts: 9
- Joined: Fri Mar 30, 2018 4:58 pm
I have a use case that requires that my application handles long path names ( over 260 chars ). Currently building against 3.1.4 Unicode and testing this on Windows 10. Pre-pending the usual Win32 prefix "\\?\" does not seem to work.
Here is a code snippet:
Code: Select all
wxString Path = "........";
wxString LongPath = "\\\\?\\" + Path;
wxFFileOutputStream* m_pOut = new wxFFileOutputStream(LongPath);
m_pOut above fails for long paths but passes for shorter paths. I know internally wxFFileOutputStream uses wxFFile to open the file using the CRT wrapper function wxFopen.
This is the first time I'm dealing with long paths in wx, anyone with ideas for how to get around this? Or just maybe something I'm missing.
- Part Of The Furniture
- Posts: 4543
- Joined: Sat Apr 16, 2005 7:22 am
- Location: USA, Ukraine
Can you provide some sample path?
Can wx program create such a path?
Also - what do you mean by "fail for a long path"? Crash?? Nothing happened? Wrong result?