How to create a file link through windows command and define start in directory for that link?

  .net-5, c++, command-line, mklink, windows

I need to make a shortcut for my application and the shortcut needs to have the same icon, so no bat files come into consideration instead of the shortcut. I also want a native windows solution or .NET 5.0 solution, not a third party program, I want to be as low to the source as possible.

I’ve tried mklink but it does not provide an option to set shortcut’s "Start in:" directory which is crucial for my app for which I need to make a shortcut.

I don’t understand why making a simple shortcut is such an obscure thing, one which you can create with two clicks.

Source: Windows Questions

LEAVE A COMMENT