|
|
Home » U++ Library support » FileSel&FileList, Path » FEATURE REQUEST: Navigation by desktop shortcuts
|
|
|
|
|
Re: FEATURE REQUEST: Navigation by desktop shortcuts [message #52655 is a reply to message #52653] |
Thu, 07 November 2019 14:33 |
|
mirek
Messages: 14039 Registered: November 2005
|
Ultimate Member |
|
|
pvictor wrote on Thu, 07 November 2019 11:55Hello, Mirek.
I researched the problem and found that there are different .lnk files on my desktop.
I attached three of them.
The file СТМ32.lnk points to local directory and it works OK.
Other two files point to network and don't work (they are opened as empty files).
All the .lnk files are shown as files, not as folders (it would be better).
Best regards,
Victor
Well, sending .lnk files does not really help
Can you test this for me:
#include <CtrlLib/CtrlLib.h>
using namespace Upp;
GUI_APP_MAIN
{
String path = "C:/Users/cxl/Desktop/Files.lnk";
DDUMP(path);
DDUMP(FileExists(path));
String t = GetSymLinkPath(path);
DDUMP(t);
DDUMP(DirectoryExists(t));
}
Please replace path with other dirs that do now work too and send me the .log file.
As for showing .lnk as files, well, not all .lnk lead to dirs. Unfortunately detecting that .lnk points to dir is potentially time consuming so it has to be done 'later'. BTW it looks like windows shell also shows .lnk of dirs between files, probably for the same reason...
[Updated on: Thu, 07 November 2019 14:35] Report message to a moderator
|
|
|
|
|
|
|
Re: FEATURE REQUEST: Navigation by desktop shortcuts [message #52662 is a reply to message #52661] |
Fri, 08 November 2019 09:35 |
pvictor
Messages: 68 Registered: December 2015
|
Member |
|
|
Mirek, I looked at it in debugger.
File: Path.cpp
bool FindFile::Search(const char *name) {
pattern = GetFileName(name);
path = NormalizePath(GetFileDirectory(name));
Close();
handle = FindFirstFileW(ToSystemCharsetW(name), data);
if(handle == INVALID_HANDLE_VALUE)
return false; <-- returns here
if(!PatternMatch(pattern, GetName()))
return Next();
return true;
}
name contains "\\\\1336data\\Constructor"
Victor
[Updated on: Fri, 08 November 2019 09:38] Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|
|
Goto Forum:
Current Time: Fri Sep 20 23:24:26 CEST 2024
Total time taken to generate the page: 0.03740 seconds
|
|
|