tags:

views:

350

answers:

0

Hi all, I'm having a problem with setting long unc path as the target of a shortcut file on Windows 2008. The particular code is like:

IShellLinkW* link =... 
link->SetPath(filename);

We then pass a long UNC path, in the form of "\?\UNC..." in as filename. This call works when we do it on Windows 2003. But on Windows 2008, the calls fails and returns E_INVALIDARG. Removing the "\?\UNC\" at the start and then the code works, but then we can't use long path names. Does anyone know why this happens or a work around?