PathCompactPath

[DllImport("shlwapi.dll", CharSet = CharSet.Unicode)]
public static extern bool PathCompactPath(
   IntPtr hDC,
   StringBuilder pszPath,
   uint dx
);

Microsoft documentation: Link

Last updated