// 1. Get the Desktop Path string desktopPath = Environment.GetFolderPath(Environment.SpecialFolder.Desktop); string shortcutLocation = Path.Combine(desktopPath, appName + ".lnk");
Windows offers several ways to pin items to your desktop, ranging from simple drag-and-drop actions to formal context menus.
The feature should be invocable from two locations: create a desktop icon
Log.Error($"Failed to create shortcut: ex.Message"); return false;
| ID | Criteria | |----|----------| | | The system creates a valid shortcut file ( .lnk for Windows, .desktop or Alias for macOS/Linux) on the user's desktop directory. | | AC-02 | The shortcut uses the application’s designated high-resolution icon. | | AC-03 | The shortcut points to the correct executable path (including version-specific paths if applicable). | | AC-04 | If a shortcut already exists, the system overwrites it or prompts the user (configurable behavior). | | AC-05 | If the user lacks write permissions for the desktop directory, a graceful error message is displayed. | | | AC-02 | The shortcut uses the
: Open your preferred web browser.
: Go to the website you want to create a desktop icon for. | | AC-05 | If the user lacks
Here’s a general review of the process or tool for (depending on whether you mean a native Windows/macOS feature or a third-party software):
: Click on File > Share > Add to Dock or use the Share button and select Add Bookmark to Dock if available.