Creating a shortcut

using System.Runtime.InteropServices;
[DllImport("coredll.dll")]
public static extern void SHCreateShortcut(
string target,
string shortcut);
// Create a shortcut to tmail.exe within the
// windows start menu.
SHCreateShortcut(
@"\windows\start menu\programs\test.lnk",
@"\windows\test.exe");
[DllImport("coredll.dll")]
public static extern void SHCreateShortcut(
string target,
string shortcut);
// Create a shortcut to tmail.exe within the
// windows start menu.
SHCreateShortcut(
@"\windows\start menu\programs\test.lnk",
@"\windows\test.exe");
留言